wxBitmapRefData *ref = (wxBitmapRefData *)ret.GetRefData();
ref->m_numColors = M_BITMAPDATA->m_numColors;
- ref->m_bitmapPalette = M_BITMAPDATA->m_bitmapPalette;
+#if wxUSE_PALETTE
+ ref->m_bitmapPalette = M_BITMAPDATA->m_bitmapPalette;
+#endif // wxUSE_PALETTE
ref->m_bitmapType = M_BITMAPDATA->m_bitmapType;
// Copy sub region of this bitmap
wxBitmap::wxBitmap(const wxImage& image, int depth)
{
wxCHECK_RET( image.Ok(), wxT("invalid image") )
- wxCHECK_RET( depth == -1, wxT("invalid bitmap depth") )
m_refData = new wxBitmapRefData();
M_BITMAPDATA->m_ok = isOk;
}
+#if wxUSE_PALETTE
wxPalette *wxBitmap::GetPalette() const
{
wxCHECK_MSG( Ok(), NULL, wxT("Invalid bitmap GetPalette()") );
M_BITMAPDATA->m_bitmapPalette = palette ;
}
+#endif // wxUSE_PALETTE
void wxBitmap::SetMask(wxMask *mask)
{