Don't use default size of control has a sizer (as per other ports)
authorRobert Roebling <robert@roebling.de>
Wed, 18 Feb 2009 21:20:04 +0000 (21:20 +0000)
committerRobert Roebling <robert@roebling.de>
Wed, 18 Feb 2009 21:20:04 +0000 (21:20 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59005 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/control.cpp

index 5c1740dfad2979409fd36c46fb5d43605d1130f7..b3e4f5b2ec66808313ca218bd35a6bb9fabad025 100644 (file)
@@ -245,6 +245,9 @@ WXDWORD wxControl::MSWGetStyle(long style, WXDWORD *exstyle) const
 
 wxSize wxControl::DoGetBestSize() const
 {
+    if (m_windowSizer)
+       return wxControlBase::DoGetBestSize();
+       
     return wxSize(DEFAULT_ITEM_WIDTH, DEFAULT_ITEM_HEIGHT);
 }