Browse Source

fixed container's bounds updating

Andrew Karpushin 11 years ago
parent
commit
ce2c33e13e
1 changed files with 3 additions and 3 deletions
  1. 3 3
      gameplay/src/Container.cpp

+ 3 - 3
gameplay/src/Container.cpp

@@ -543,9 +543,6 @@ void Container::updateState(State state)
 
 
 void Container::updateBounds()
 void Container::updateBounds()
 {
 {
-    // Compute total bounds of container
-    Control::updateBounds();
-
     // Handle automatically sizing based on our children
     // Handle automatically sizing based on our children
     if (_autoSize != AUTO_SIZE_NONE)
     if (_autoSize != AUTO_SIZE_NONE)
     {
     {
@@ -590,6 +587,9 @@ void Container::updateBounds()
         }
         }
     }
     }
 
 
+    // Compute total bounds of container
+    Control::updateBounds();
+
     // Update layout to position children correctly within us
     // Update layout to position children correctly within us
     GP_ASSERT(_layout);
     GP_ASSERT(_layout);
     _layout->update(this);
     _layout->update(this);