diff --git a/src/generic/tbarsmpl.cpp b/src/generic/tbarsmpl.cpp index c019f0f43f..10f4cf1103 100644 --- a/src/generic/tbarsmpl.cpp +++ b/src/generic/tbarsmpl.cpp @@ -557,7 +557,8 @@ void wxToolBarSimple::DrawTool(wxDC& dc, wxToolBarToolBase *toolBase) #if wxUSE_PALETTE #ifndef __WXGTK__ - memDC.SetPalette(wxNullPalette); + if (bitmap.GetPalette()) + memDC.SetPalette(wxNullPalette); #endif #endif // wxUSE_PALETTE }