]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/statbmp.cpp
wxFrame: OnSize() has a SEGV if wxFrame has no child. Fixed.
[wxWidgets.git] / src / msw / statbmp.cpp
index 5c0483014dfccc8714b05d92c31470fac41f6848..14b4f94c9b8acf7f848cd57469126dc3f7313c68 100644 (file)
@@ -154,7 +154,7 @@ bool wxStaticBitmap::MSWOnDraw(WXDRAWITEMSTRUCT *item)
        HDC hDC = lpDIS->hDC;
        HDC memDC = ::CreateCompatibleDC(hDC);
 
-       HBITMAP old = ::SelectObject(memDC, (HBITMAP) bitmap->GetHBITMAP());
+       HBITMAP old = (HBITMAP) ::SelectObject(memDC, (HBITMAP) bitmap->GetHBITMAP());
 
        if (!old)
                return FALSE;