X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/19193a2c85987b595932957e73013e7ea100f0e8..8f4fcc4ee080b020057cc028a809ffc884f63bb8:/src/os2/dc.cpp diff --git a/src/os2/dc.cpp b/src/os2/dc.cpp index d2fe58841f..2bee9f08e6 100644 --- a/src/os2/dc.cpp +++ b/src/os2/dc.cpp @@ -542,6 +542,18 @@ int wxDC::GetDepth() const void wxDC::Clear() { + // + // If this is a canvas DC then just fill with the background color + // Otherwise purge the whole thing + // + if (m_pCanvas) + { + RECTL vRect; + + ::GpiQueryClipBox(m_hPS, &vRect); + ::WinFillRect(m_hPS, &vRect, ::GpiQueryBackColor(m_hPS)); + } + else ::GpiErase(m_hPS); } // end of wxDC::Clear