X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c354beeafacc20831ce76e266703d07f27e826c7..bb24c68f3502746147337c3f502cc1c957bcfb35:/src/os2/dcclient.cpp diff --git a/src/os2/dcclient.cpp b/src/os2/dcclient.cpp index 4bb99210df..083b902b3d 100644 --- a/src/os2/dcclient.cpp +++ b/src/os2/dcclient.cpp @@ -319,12 +319,14 @@ wxPaintDC::wxPaintDC( { HPS hPS; + m_hDC = ::WinOpenWindowDC(GetWinHwnd(m_pCanvas)); hPS = ::WinBeginPaint( GetWinHwnd(m_pCanvas) ,NULLHANDLE ,&g_paintStruct ); if(hPS) { + ::GpiAssociate(hPS, m_hDC); m_hOldPS = m_hPS; m_hPS = hPS; ::GpiCreateLogColorTable( m_hPS @@ -349,7 +351,6 @@ wxPaintDC::wxPaintDC( } m_bIsPaintTime = TRUE; - m_hDC = (WXHDC) -1; // to satisfy those anonizmous efforts ms_cache.Add(new wxPaintDCInfo(m_pCanvas, this)); } InitDC();