aboutsummaryrefslogtreecommitdiffstats
path: root/src/com/itmill/toolkit/ui/AbstractComponent.java
diff options
context:
space:
mode:
authorJoonas Lehtinen <joonas.lehtinen@itmill.com>2007-09-30 13:56:37 +0000
committerJoonas Lehtinen <joonas.lehtinen@itmill.com>2007-09-30 13:56:37 +0000
commitddd21c36586473dc3123cb27b6af153de4e99fa0 (patch)
tree1a9a8e1f2c2caed635b356d4579e104e5c1f49dc /src/com/itmill/toolkit/ui/AbstractComponent.java
parent00596710405fa2c56a7b51a7f237cfc5bd170ca4 (diff)
downloadvaadin-framework-ddd21c36586473dc3123cb27b6af153de4e99fa0.tar.gz
vaadin-framework-ddd21c36586473dc3123cb27b6af153de4e99fa0.zip
UIDL Caching system implemenatation. Closes #855
svn changeset:2396/svn branch:trunk
Diffstat (limited to 'src/com/itmill/toolkit/ui/AbstractComponent.java')
-rw-r--r--src/com/itmill/toolkit/ui/AbstractComponent.java10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/com/itmill/toolkit/ui/AbstractComponent.java b/src/com/itmill/toolkit/ui/AbstractComponent.java
index 9befb25f1c..18ce5b59a5 100644
--- a/src/com/itmill/toolkit/ui/AbstractComponent.java
+++ b/src/com/itmill/toolkit/ui/AbstractComponent.java
@@ -518,6 +518,7 @@ public abstract class AbstractComponent implements Component, MethodEventSource
* interface.
*/
public void attach() {
+ requestRepaint();
}
/*
@@ -551,7 +552,10 @@ public abstract class AbstractComponent implements Component, MethodEventSource
*/
public final void paint(PaintTarget target) throws PaintException {
- if (!target.startTag(this, this.getTag())) {
+ if (!target.startTag(this, this.getTag()) || repaintRequestListenersNotified) {
+
+ // Paint the contents of the component
+
if (styles != null && styles.size() > 0)
target.addAttribute("style", getStyle());
if (isReadOnly())
@@ -580,6 +584,10 @@ public abstract class AbstractComponent implements Component, MethodEventSource
if (error != null)
error.paint(target);
}
+ } else {
+
+ // Contents have not changed, only cached presentation can be used
+ target.addAttribute("cached", true);
}
target.endTag(this.getTag());