]> git.saurik.com Git - wxWidgets.git/blobdiff - src/os2/toplevel.cpp
Fix for crash when opening empty node
[wxWidgets.git] / src / os2 / toplevel.cpp
index b231df5bff132b39f6ae596b0771ebd517478302..e076e5019770769b0bef482b373e40476e673031 100644 (file)
@@ -1004,9 +1004,9 @@ void wxTopLevelWindowOS2::SetIcons(
     //
     wxTopLevelWindowBase::SetIcons(rIcons);
 
     //
     wxTopLevelWindowBase::SetIcons(rIcons);
 
-    const wxIcon& vIcon = rIcons.GetIcon(32);
+    const wxIcon& vIcon = rIcons.GetIconOfExactSize(32);
 
 
-    if (vIcon.Ok() && vIcon.GetWidth() == 32 && vIcon.GetHeight() == 32)
+    if (vIcon.Ok())
     {
         ::WinSendMsg( m_hFrame
                      ,WM_SETICON
     {
         ::WinSendMsg( m_hFrame
                      ,WM_SETICON