X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/17f504ec9d688dc61bf10090a808a25ba34c50af..98cb8dcb0cf3b0e660f1f67e1c02451ab10257de:/src/gtk/bitmap.cpp diff --git a/src/gtk/bitmap.cpp b/src/gtk/bitmap.cpp index 1a4c20bb62..46ffd4b0ca 100644 --- a/src/gtk/bitmap.cpp +++ b/src/gtk/bitmap.cpp @@ -1,5 +1,5 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: bitmap.cpp +// Name: src/gtk/bitmap.cpp // Purpose: // Author: Robert Roebling // RCS-ID: $Id$ @@ -71,11 +71,13 @@ wxMask::wxMask( const wxBitmap& bitmap, const wxColour& colour ) Create( bitmap, colour ); } +#if wxUSE_PALETTE wxMask::wxMask( const wxBitmap& bitmap, int paletteIndex ) { m_bitmap = (GdkBitmap *) NULL; Create( bitmap, paletteIndex ); } +#endif // wxUSE_PALETTE wxMask::wxMask( const wxBitmap& bitmap ) { @@ -182,6 +184,7 @@ bool wxMask::Create( const wxBitmap& bitmap, return true; } +#if wxUSE_PALETTE bool wxMask::Create( const wxBitmap& bitmap, int paletteIndex ) { unsigned char r,g,b; @@ -193,6 +196,7 @@ bool wxMask::Create( const wxBitmap& bitmap, int paletteIndex ) return Create(bitmap, wxColour(r, g, b)); } +#endif // wxUSE_PALETTE bool wxMask::Create( const wxBitmap& bitmap ) { @@ -271,7 +275,9 @@ wxBitmapRefData::~wxBitmapRefData() gdk_pixbuf_unref( m_pixbuf ); #endif delete m_mask; +#if wxUSE_PALETTE delete m_palette; +#endif // wxUSE_PALETTE } //----------------------------------------------------------------------------- @@ -1388,6 +1394,7 @@ bool wxBitmap::LoadFile( const wxString &name, wxBitmapType type ) return true; } +#if wxUSE_PALETTE wxPalette *wxBitmap::GetPalette() const { if (!Ok()) @@ -1400,6 +1407,7 @@ void wxBitmap::SetPalette(const wxPalette& WXUNUSED(palette)) { // TODO } +#endif // wxUSE_PALETTE void wxBitmap::SetHeight( int height ) { @@ -1658,5 +1666,3 @@ bool wxBitmapHandler::SaveFile(const wxBitmap * WXUNUSED(bitmap), { // TODO: Insert handler based on GdkPixbufs handler later } - -