X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/48e487e37f0eee80bfa8b176b95a234a9b34aa8a..400930d3445bd8d8745c621b9ad0b352433db622:/src/generic/statbmpg.cpp?ds=inline diff --git a/src/generic/statbmpg.cpp b/src/generic/statbmpg.cpp index da1ad895cf..735c0b9d32 100644 --- a/src/generic/statbmpg.cpp +++ b/src/generic/statbmpg.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////////// -// Name: src/generic/statbmp.cpp +// Name: src/generic/statbmpg.cpp // Purpose: wxGenericStaticBitmap // Author: Marcin Wojdyr, Stefan Csomor // Created: 2008-06-16 @@ -18,8 +18,6 @@ #include "wx/generic/statbmpg.h" -IMPLEMENT_DYNAMIC_CLASS(wxGenericStaticBitmap, wxStaticBitmapBase) - bool wxGenericStaticBitmap::Create(wxWindow *parent, wxWindowID id, const wxBitmap& bitmap, const wxPoint& pos, const wxSize& size, @@ -36,10 +34,16 @@ bool wxGenericStaticBitmap::Create(wxWindow *parent, wxWindowID id, void wxGenericStaticBitmap::OnPaint(wxPaintEvent& WXUNUSED(event)) { wxPaintDC dc(this); - PrepareDC(dc); - if (m_bitmap.Ok()) + if (m_bitmap.IsOk()) dc.DrawBitmap(m_bitmap, 0, 0, true); } +// under OSX_cocoa is a define, avoid duplicate info +#ifndef wxGenericStaticBitmap + +IMPLEMENT_DYNAMIC_CLASS(wxGenericStaticBitmap, wxStaticBitmapBase) + +#endif + #endif // wxUSE_STATBMP