diff --git a/src/msw/icon.cpp b/src/msw/icon.cpp index 8f27b61324..4e6eccd235 100644 --- a/src/msw/icon.cpp +++ b/src/msw/icon.cpp @@ -143,6 +143,9 @@ void wxIcon::CopyFromBitmap(const wxBitmap& bmp) // we created the mask, now delete it delete mask; } + + // delete the inverted mask bitmap we created as well + ::DeleteObject(iconInfo.hbmMask); #else // Win16 // there are some functions in curico.cpp which probably could be used // here...