X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8ecff18117f8cabc0f515ad81aa4ad265e5e17d3..69659fd770f615210efac4b4fa741b3ad6223616:/src/msw/icon.cpp?ds=sidebyside diff --git a/src/msw/icon.cpp b/src/msw/icon.cpp index 67f83d31f6..ebf8f49d98 100644 --- a/src/msw/icon.cpp +++ b/src/msw/icon.cpp @@ -144,8 +144,14 @@ bool wxIcon::LoadFile(const wxString& filename, if ( !handler ) { - // say something? - return false; + // load via wxBitmap which, in turn, uses wxImage allowing us to + // support more formats + wxBitmap bmp; + if ( !bmp.LoadFile(filename, type) ) + return false; + + CopyFromBitmap(bmp); + return true; } return handler->Load(this, filename, type, desiredWidth, desiredHeight);