]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/sizer.cpp
no real change: put event handlers together at the end of the file
[wxWidgets.git] / src / common / sizer.cpp
index 375f5c282496db1794aa40089a415a9e6fc64ed1..173a0a48106109f8a2e42dfd14d2bb57f511ffed 100644 (file)
@@ -480,10 +480,21 @@ void wxSizerItem::SetDimension( const wxPoint& pos_, const wxSize& size_ )
             break;
 
         case Item_Window:
+        {
+            // Use wxSIZE_FORCE_EVENT here since a sizer item might
+            // have changed alignment or some other property which would
+            // not change the size of the window. In such a case, no
+            // wxSizeEvent would normally be generated and thus the
+            // control wouldn't get layed out correctly here.
+#if 1
+            m_window->SetSize(pos.x, pos.y, size.x, size.y,
+                              wxSIZE_ALLOW_MINUS_ONE|wxSIZE_FORCE_EVENT );
+#else
             m_window->SetSize(pos.x, pos.y, size.x, size.y,
-                              wxSIZE_ALLOW_MINUS_ONE);
+                              wxSIZE_ALLOW_MINUS_ONE );
+#endif
             break;
-
+        }
         case Item_Sizer:
             m_sizer->SetDimension(pos, size);
             break;
@@ -2237,7 +2248,7 @@ void wxStdDialogButtonSizer::Realize()
         }
 
         // Extra space around and at the right
-        Add(12, 24);
+        Add(12, 40);
 #elif defined(__WXGTK20__)
         Add(0, 0, 0, wxLEFT, 9);
         if (m_buttonHelp)