]> git.saurik.com Git - wxWidgets.git/commitdiff
Paint bugfix
authorJulian Smart <julian@anthemion.co.uk>
Tue, 31 May 2005 11:12:54 +0000 (11:12 +0000)
committerJulian Smart <julian@anthemion.co.uk>
Tue, 31 May 2005 11:12:54 +0000 (11:12 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@34445 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/msw/mediactrl.cpp

index 84f5bc6888a4521374b644e9a4dba9e3dbef8dd5..ad5ca83d4c564c165ec5f7052207b0095b615c69 100644 (file)
@@ -1639,10 +1639,13 @@ void wxAMMediaEvtHandler::OnPaint(wxPaintEvent& WXUNUSED(evt))
 {
     wxAMMediaBackend* pThis = (wxAMMediaBackend*) this;
     wxPaintDC dc(pThis->m_ctrl);
-    if( pThis->m_pVMC->RepaintVideo((HWND)pThis->m_ctrl->GetHandle(), 
-                                            (HDC)dc.GetHDC())  != 0 )
+    if( pThis->m_pVMC )
     {
-        wxASSERT(false);
+        if( pThis->m_pVMC->RepaintVideo((HWND)pThis->m_ctrl->GetHandle(), 
+                                                (HDC)dc.GetHDC())  != 0 )
+        {
+            wxASSERT(false);
+        }
     }
 }