]> source.dussan.org Git - vaadin-framework.git/commitdiff
fixes #3724, fixed size change propagation
authorMatti Tahvonen <matti.tahvonen@itmill.com>
Wed, 18 Nov 2009 09:17:57 +0000 (09:17 +0000)
committerMatti Tahvonen <matti.tahvonen@itmill.com>
Wed, 18 Nov 2009 09:17:57 +0000 (09:17 +0000)
svn changeset:9859/svn branch:6.2

src/com/vaadin/terminal/gwt/client/ui/VCssLayout.java

index 813901a56497e3b0e478049cf995d4716c947fde..ebd201724b0386582a6fac254158327c875b405f 100644 (file)
@@ -239,14 +239,17 @@ public class VCssLayout extends SimplePanel implements Paintable, Container {
 
     public boolean requestLayout(Set<Paintable> children) {
         if (hasSize()) {
-            return false;
-        } else {
             return true;
+        } else {
+            // Size may have changed
+            // TODO optimize this: cache size if not fixed, handle both width
+            // and height separately
+            return false;
         }
     }
 
     private boolean hasSize() {
-        return hasWidth || hasHeight;
+        return hasWidth && hasHeight;
     }
 
     private static final String makeCamelCase(String cssProperty) {