diff --git a/src/common/effects.cpp b/src/common/effects.cpp index a70f7032e2..e72542ecf4 100644 --- a/src/common/effects.cpp +++ b/src/common/effects.cpp @@ -88,14 +88,13 @@ void wxEffects::DrawSunkenEdge(wxDC& dc, const wxRect& rect, int WXUNUSED(border bool wxEffects::TileBitmap(const wxRect& rect, wxDC& dc, const wxBitmap& bitmap) { - static bool hiColour = (wxDisplayDepth() >= 16) ; - int w = bitmap.GetWidth(); int h = bitmap.GetHeight(); wxMemoryDC dcMem; #if wxUSE_PALETTE + static bool hiColour = (wxDisplayDepth() >= 16) ; if (bitmap.GetPalette() && !hiColour) { dc.SetPalette(* bitmap.GetPalette());