diff --git a/include/wx/generic/statbmpg.h b/include/wx/generic/statbmpg.h index 8a8fa15dfd..f3d198df4e 100644 --- a/include/wx/generic/statbmpg.h +++ b/include/wx/generic/statbmpg.h @@ -60,8 +60,8 @@ public: private: wxSize GetBitmapSize() { - return m_bitmap.IsOk() ? wxSize(m_bitmap.GetWidth(), m_bitmap.GetHeight()) - : wxSize(16, 16); // this is completely arbitrary + return m_bitmap.IsOk() ? m_bitmap.GetScaledSize() + : wxSize(16, 16); // this is completely arbitrary } void OnPaint(wxPaintEvent& event); diff --git a/src/common/ctrlcmn.cpp b/src/common/ctrlcmn.cpp index 32bce06c6f..dbfbc9f700 100644 --- a/src/common/ctrlcmn.cpp +++ b/src/common/ctrlcmn.cpp @@ -584,7 +584,7 @@ wxSize wxStaticBitmapBase::DoGetBestSize() const wxSize best; wxBitmap bmp = GetBitmap(); if ( bmp.IsOk() ) - best = wxSize(bmp.GetWidth(), bmp.GetHeight()); + best = bmp.GetScaledSize(); else // this is completely arbitrary best = wxSize(16, 16); diff --git a/src/osx/bmpbuttn_osx.cpp b/src/osx/bmpbuttn_osx.cpp index 581ddd0865..fcc4b9ccf2 100644 --- a/src/osx/bmpbuttn_osx.cpp +++ b/src/osx/bmpbuttn_osx.cpp @@ -66,7 +66,7 @@ wxSize wxBitmapButton::DoGetBestSize() const if ( GetBitmapLabel().IsOk() ) { - best += GetBitmapLabel().GetSize(); + best += GetBitmapLabel().GetScaledSize(); } return best;