]> source.dussan.org Git - vaadin-framework.git/commitdiff
Always paint child components as deferred to ensure the state is sent to
authorArtur Signell <artur@vaadin.com>
Thu, 15 Mar 2012 12:58:06 +0000 (14:58 +0200)
committerArtur Signell <artur@vaadin.com>
Thu, 15 Mar 2012 12:58:06 +0000 (14:58 +0200)
the client

src/com/vaadin/terminal/gwt/server/JsonPaintTarget.java

index 4470970095d20911cd15e73646f6309c5d5d93c6..8a57d2110ea7b73251104c5f40ba56924fa5f584 100644 (file)
@@ -702,16 +702,16 @@ public class JsonPaintTarget implements PaintTarget {
         openPaintables.push(paintable);
         openPaintableTags.push(tagName);
 
-        if (cacheEnabled && isPreviouslyPainted) {
-            // cached (unmodified) paintable, paint the it now
-            paintedComponents.add(paintable);
-            deferredPaintables.remove(paintable);
-            return PaintStatus.CACHED;
-        } else if (!topLevelPaintableTag) {
+        if (!topLevelPaintableTag) {
             // notify manager: add to paint queue instead of painting now
             manager.queuePaintable(paintable);
             deferredPaintables.add(paintable);
             return PaintStatus.DEFER;
+        } else if (cacheEnabled && isPreviouslyPainted) {
+            // cached (unmodified) paintable, paint the it now
+            paintedComponents.add(paintable);
+            deferredPaintables.remove(paintable);
+            return PaintStatus.CACHED;
         } else {
             // not a nested paintable, paint the it now
             paintedComponents.add(paintable);