]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/control.cpp
compilation fix after wxBitmap image changes
[wxWidgets.git] / src / msw / control.cpp
index 5c1740dfad2979409fd36c46fb5d43605d1130f7..06d75a9921d9c79b989ba197d1de87283c4ec012 100644 (file)
@@ -143,13 +143,11 @@ bool wxControl::MSWCreateControl(const wxChar *classname,
 
     if ( !m_hWnd )
     {
 
     if ( !m_hWnd )
     {
-#ifdef __WXDEBUG__
         wxLogLastError(wxString::Format
                        (
                         _T("CreateWindowEx(\"%s\", flags=%08lx, ex=%08lx)"),
                         classname, style, exstyle
                        ));
         wxLogLastError(wxString::Format
                        (
                         _T("CreateWindowEx(\"%s\", flags=%08lx, ex=%08lx)"),
                         classname, style, exstyle
                        ));
-#endif // __WXDEBUG__
 
         return false;
     }
 
         return false;
     }
@@ -245,6 +243,9 @@ WXDWORD wxControl::MSWGetStyle(long style, WXDWORD *exstyle) const
 
 wxSize wxControl::DoGetBestSize() const
 {
 
 wxSize wxControl::DoGetBestSize() const
 {
+    if (m_windowSizer)
+       return wxControlBase::DoGetBestSize();
+       
     return wxSize(DEFAULT_ITEM_WIDTH, DEFAULT_ITEM_HEIGHT);
 }
 
     return wxSize(DEFAULT_ITEM_WIDTH, DEFAULT_ITEM_HEIGHT);
 }