X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9266e0ecde7600d5907f8a737d10f6e2ba365613..01cca03e20a1c58c977e1ea1252fda8c383ded5b:/src/msw/bmpbuttn.cpp diff --git a/src/msw/bmpbuttn.cpp b/src/msw/bmpbuttn.cpp index e1be21611f..b8ae50c907 100644 --- a/src/msw/bmpbuttn.cpp +++ b/src/msw/bmpbuttn.cpp @@ -9,10 +9,6 @@ // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -#pragma implementation "bmpbuttn.h" -#endif - // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" @@ -103,8 +99,6 @@ bitmap "focus" , bitmap "disabled" , */ -#define BUTTON_HEIGHT_FACTOR (EDIT_CONTROL_FACTOR * 1.1) - bool wxBitmapButton::Create(wxWindow *parent, wxWindowID id, const wxBitmap& bitmap, const wxPoint& pos, @@ -494,8 +488,10 @@ wxSize wxBitmapButton::DoGetBestSize() const { if ( m_bmpNormal.Ok() ) { - return wxSize(m_bmpNormal.GetWidth() + 2*m_marginX, + wxSize best(m_bmpNormal.GetWidth() + 2*m_marginX, m_bmpNormal.GetHeight() + 2*m_marginY); + CacheBestSize(best); + return best; } // no idea what our best size should be, defer to the base class