]> source.dussan.org Git - vaadin-framework.git/commitdiff
Changed addComponent() a bit: must call super, can't call setParent() directly.
authorMarc Englund <marc.englund@itmill.com>
Fri, 1 Feb 2008 14:46:02 +0000 (14:46 +0000)
committerMarc Englund <marc.englund@itmill.com>
Fri, 1 Feb 2008 14:46:02 +0000 (14:46 +0000)
svn changeset:3706/svn branch:trunk

src/com/itmill/toolkit/ui/GridLayout.java

index ec56136e2215f14368f8a2cebe7617603fc5c5ca..ad91568390c0d05248905ab9240bb42f803be919 100644 (file)
@@ -193,9 +193,12 @@ public class GridLayout extends AbstractLayout {
         // Checks that newItem does not overlap with existing items
         checkExistingOverlaps(area);
 
+        // first attemt to add to super
+        super.addComponent(component);
+
         // Inserts the component to right place at the list
         // Respect top-down, left-right ordering
-        component.setParent(this);
+        // component.setParent(this);
         final Iterator i = areas.iterator();
         int index = 0;
         boolean done = false;
@@ -214,7 +217,6 @@ public class GridLayout extends AbstractLayout {
             components.addLast(component);
         }
 
-        super.addComponent(component);
         requestRepaint();
     }