X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/650c0aa9180563eece310851973171cfaac83ad8..38400bb46b1477680ec08ed04f2bcafa8de5e3bf:/src/gtk1/bitmap.cpp?ds=sidebyside diff --git a/src/gtk1/bitmap.cpp b/src/gtk1/bitmap.cpp index 5948f4dfdf..daa51e4dc5 100644 --- a/src/gtk1/bitmap.cpp +++ b/src/gtk1/bitmap.cpp @@ -224,7 +224,7 @@ GdkBitmap *wxMask::GetBitmap() const // wxBitmap //----------------------------------------------------------------------------- -class wxBitmapRefData: public wxObjectRefData +class wxBitmapRefData : public wxGDIRefData { public: wxBitmapRefData(); @@ -232,6 +232,8 @@ public: bool Create(int width, int height, int bpp); virtual ~wxBitmapRefData(); + virtual bool IsOk() const { return m_pixmap || m_bitmap; } + GdkPixmap *m_pixmap; GdkBitmap *m_bitmap; wxMask *m_mask; @@ -360,12 +362,12 @@ wxBitmap::wxBitmap( int width, int height, int depth ) Create( width, height, depth ); } -wxObjectRefData *wxBitmap::CreateRefData() const +wxGDIRefData *wxBitmap::CreateGDIRefData() const { return new wxBitmapRefData; } -wxObjectRefData *wxBitmap::CloneRefData(const wxObjectRefData *data) const +wxGDIRefData *wxBitmap::CloneGDIRefData(const wxGDIRefData *data) const { return new wxBitmapRefData(*wx_static_cast(const wxBitmapRefData *, data)); } @@ -1137,12 +1139,6 @@ wxBitmap::~wxBitmap() { } -bool wxBitmap::IsOk() const -{ - return (m_refData != NULL) && - (M_BMPDATA->m_bitmap || M_BMPDATA->m_pixmap); -} - int wxBitmap::GetHeight() const { wxCHECK_MSG( Ok(), -1, wxT("invalid bitmap") ); @@ -1363,7 +1359,7 @@ GdkBitmap *wxBitmap::GetBitmap() const return M_BMPDATA->m_bitmap; } -void *wxBitmap::GetRawData(wxPixelDataBase& data, int bpp) +void *wxBitmap::GetRawData(wxPixelDataBase& WXUNUSED(data), int WXUNUSED(bpp)) { return NULL; }