X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/973b0afb1e0d469c322c34d148a382bbea285d6c..7ef4c90b0a4a657d2d34a21b397dfe20b565f894:/src/mac/carbon/bitmap.cpp diff --git a/src/mac/carbon/bitmap.cpp b/src/mac/carbon/bitmap.cpp index 70d0a07761..9e47fe6728 100644 --- a/src/mac/carbon/bitmap.cpp +++ b/src/mac/carbon/bitmap.cpp @@ -23,10 +23,6 @@ #include "wx/image.h" #include "wx/xpmdecod.h" -#ifndef __UNIX__ - #define OBSOLETE_XPM_DATA_HANDLER -#endif - extern "C" { #ifdef OBSOLETE_XPM_DATA_HANDLER @@ -205,6 +201,7 @@ wxBitmapRefData::wxBitmapRefData() m_bitmapMask = NULL; m_hBitmap = NULL ; m_hPict = NULL ; + m_hIcon = NULL ; m_bitmapType = kMacBitmapTypeUnknownType ; } @@ -230,6 +227,13 @@ wxBitmapRefData::~wxBitmapRefData() } } break ; + case kMacBitmapTypeIcon : + if ( m_hIcon ) + { + DisposeCIcon( m_hIcon ) ; + m_hIcon = NULL ; + } + default : // unkown type ? break ; @@ -492,7 +496,7 @@ void wxBitmap::SetHBITMAP(WXHBITMAP bmp) { M_BITMAPDATA->m_bitmapType = kMacBitmapTypeGrafWorld ; M_BITMAPDATA->m_hBitmap = bmp ; - M_BITMAPDATA->m_ok = (M_BITMAPDATA->m_hBitmap != NULL ) ; + M_BITMAPDATA->m_ok = (M_BITMAPDATA->m_hBitmap != NULL ) ; } bool wxBitmap::LoadFile(const wxString& filename, long type)