X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9a83f860948059b0273b5cc6d9e43fadad3ebfca..404b319a85dadd7decf7a5a5331020520031a41c:/src/msw/icon.cpp diff --git a/src/msw/icon.cpp b/src/msw/icon.cpp index fdd9d501c3..dccefc51cc 100644 --- a/src/msw/icon.cpp +++ b/src/msw/icon.cpp @@ -156,3 +156,14 @@ bool wxIcon::LoadFile(const wxString& filename, return handler->Load(this, filename, type, desiredWidth, desiredHeight); } + +bool wxIcon::CreateFromHICON(WXHICON icon) +{ + SetHICON(icon); + if ( !IsOk() ) + return false; + + SetSize(wxGetHiconSize(icon)); + + return true; +}