X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6db34764d7ba8ea3c221b3e302d26071af944f6e..82a16d7e5e5c83e95a4caa7314de2dbfbd1debdc:/src/gtk1/bitmap.cpp diff --git a/src/gtk1/bitmap.cpp b/src/gtk1/bitmap.cpp index ea76fd0e34..4950f9508a 100644 --- a/src/gtk1/bitmap.cpp +++ b/src/gtk1/bitmap.cpp @@ -16,8 +16,8 @@ #include "wx/defs.h" -#include "wx/palette.h" #include "wx/bitmap.h" +#include "wx/palette.h" #include "wx/icon.h" #include "wx/filefn.h" #include "wx/image.h" @@ -1444,9 +1444,11 @@ GdkPixmap *wxBitmap::GetPixmap() const // create the pixmap on the fly if we use Pixbuf representation: if (HasPixbuf() && !HasPixmap()) { + delete M_BMPDATA->m_mask; + M_BMPDATA->m_mask = new wxMask(); gdk_pixbuf_render_pixmap_and_mask(M_BMPDATA->m_pixbuf, &M_BMPDATA->m_pixmap, - NULL /*mask*/, + &M_BMPDATA->m_mask->m_bitmap, 128 /*threshold*/); } #endif // __WXGTK20__