X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7c551d959447b3aea01cc35f45aa4cacff2173ba..e96360efd9015260be782e778c8076bb13cb6f5a:/src/mac/carbon/statbmp.cpp diff --git a/src/mac/carbon/statbmp.cpp b/src/mac/carbon/statbmp.cpp index 86a8528929..47aa296e1c 100644 --- a/src/mac/carbon/statbmp.cpp +++ b/src/mac/carbon/statbmp.cpp @@ -14,6 +14,7 @@ #endif #include "wx/statbmp.h" +#include "wx/dcclient.h" #if !USE_SHARED_LIBRARY IMPLEMENT_DYNAMIC_CLASS(wxStaticBitmap, wxControl) @@ -30,11 +31,12 @@ END_EVENT_TABLE() bool wxStaticBitmap::Create(wxWindow *parent, wxWindowID id, const wxBitmap& bitmap, const wxPoint& pos, - const wxSize& size, + const wxSize& s, long style, const wxString& name) { SetName(name); + wxSize size = s ; m_backgroundColour = parent->GetBackgroundColour() ; m_foregroundColour = parent->GetForegroundColour() ; @@ -48,10 +50,9 @@ bool wxStaticBitmap::Create(wxWindow *parent, wxWindowID id, m_windowStyle = style; - bool ret = wxControl::Create( parent, id, pos, size, style , name ); + bool ret = wxControl::Create( parent, id, pos, size, style , wxDefaultValidator , name ); + SetSizeOrDefault( size ) ; - SetSizeOrDefault() ; - return ret; }