X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7ecb8b06ade47981aa828a3f7fb4278f822456d3..5acc0d5f32e7a9354feb6fac7a0d439fda04a370:/src/msw/bitmap.cpp?ds=sidebyside diff --git a/src/msw/bitmap.cpp b/src/msw/bitmap.cpp index 717fc89c3e..9f62b5e7c0 100644 --- a/src/msw/bitmap.cpp +++ b/src/msw/bitmap.cpp @@ -431,8 +431,10 @@ bool wxBitmap::CreateFromImage( const wxImage& image, int depth ) if (depth == -1) depth = wxDisplayDepth(); SetDepth( depth ); +#if wxUSE_PALETTE // Copy the palette from the source image SetPalette(image.GetPalette()); +#endif // wxUSE_PALETTE // create a DIB header int headersize = sizeof(BITMAPINFOHEADER);