added wxUSE_PALETTE and fixed compilation with it set to 0
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11749 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -96,11 +96,14 @@ bool wxEffects::TileBitmap(const wxRect& rect, wxDC& dc, wxBitmap& bitmap)
|
||||
|
||||
wxMemoryDC dcMem;
|
||||
|
||||
#if wxUSE_PALETTE
|
||||
if (bitmap.GetPalette() && !hiColour)
|
||||
{
|
||||
dc.SetPalette(* bitmap.GetPalette());
|
||||
dcMem.SetPalette(* bitmap.GetPalette());
|
||||
}
|
||||
#endif // wxUSE_PALETTE
|
||||
|
||||
dcMem.SelectObject(bitmap);
|
||||
|
||||
int i, j;
|
||||
@@ -111,11 +114,13 @@ bool wxEffects::TileBitmap(const wxRect& rect, wxDC& dc, wxBitmap& bitmap)
|
||||
}
|
||||
dcMem.SelectObject(wxNullBitmap);
|
||||
|
||||
#if wxUSE_PALETTE
|
||||
if (bitmap.GetPalette() && !hiColour)
|
||||
{
|
||||
dc.SetPalette(wxNullPalette);
|
||||
dcMem.SetPalette(wxNullPalette);
|
||||
}
|
||||
#endif // wxUSE_PALETTE
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
Reference in New Issue
Block a user