]> git.saurik.com Git - wxWidgets.git/commitdiff
Explain reasoning behind using wxSIZE_FORCE_EVENT
authorRobert Roebling <robert@roebling.de>
Fri, 30 Jan 2009 23:23:31 +0000 (23:23 +0000)
committerRobert Roebling <robert@roebling.de>
Fri, 30 Jan 2009 23:23:31 +0000 (23:23 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58537 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/sizer.cpp

index 3cd52cb4ae1d5c4c8b2ecdca143aea13d81ceb46..a13599bf3ca559163113181c0695c5d04906b2bd 100644 (file)
@@ -481,6 +481,11 @@ void wxSizerItem::SetDimension( const wxPoint& pos_, const wxSize& size_ )
 
         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.
             m_window->SetSize(pos.x, pos.y, size.x, size.y,
                               wxSIZE_ALLOW_MINUS_ONE|wxSIZE_FORCE_EVENT );
             break;