X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cc374a2f2985d8783e13063a7db33c1062ca35c4..c0badb709a86b91a203416784b649e3d00c699c7:/src/mac/carbon/bmpbuttn.cpp diff --git a/src/mac/carbon/bmpbuttn.cpp b/src/mac/carbon/bmpbuttn.cpp index 48fec8aac6..2df9569de4 100644 --- a/src/mac/carbon/bmpbuttn.cpp +++ b/src/mac/carbon/bmpbuttn.cpp @@ -13,21 +13,24 @@ #if wxUSE_BMPBUTTON -#include "wx/window.h" #include "wx/bmpbuttn.h" +#ifndef WX_PRECOMP + #include "wx/window.h" +#endif + IMPLEMENT_DYNAMIC_CLASS(wxBitmapButton, wxButton) #include "wx/mac/uma.h" #include "wx/bitmap.h" bool wxBitmapButton::Create( wxWindow *parent, - wxWindowID id, const wxBitmap& bitmap, - const wxPoint& pos, - const wxSize& size, - long style, - const wxValidator& validator, - const wxString& name ) + wxWindowID id, const wxBitmap& bitmap, + const wxPoint& pos, + const wxSize& size, + long style, + const wxValidator& validator, + const wxString& name ) { m_macIsUserPane = false; @@ -55,9 +58,9 @@ bool wxBitmapButton::Create( wxWindow *parent, if ( bitmap.Ok() ) { wxSize newSize = DoGetBestSize(); - if ( width == -1 ) + if ( width == wxDefaultCoord ) width = newSize.x; - if ( height == -1 ) + if ( height == wxDefaultCoord ) height = newSize.y; }