Fixes for OS/2 wxUniv merge.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10875 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
David Webster
2001-07-06 21:47:52 +00:00
parent 537760597b
commit 0367c1c0e8
11 changed files with 851 additions and 1523 deletions

View File

@@ -218,6 +218,29 @@ wxClientDC::wxClientDC(
InitDC();
} // end of wxClientDC::wxClientDC
void wxClientDC::InitDC()
{
wxWindowDC::InitDC();
// in wxUniv build we must manually do some DC adjustments usually
// performed by Windows for us
#ifdef __WXUNIVERSAL__
wxPoint ptOrigin = m_canvas->GetClientAreaOrigin();
if ( ptOrigin.x || ptOrigin.y )
{
// no need to shift DC origin if shift is null
SetDeviceOrigin(ptOrigin.x, ptOrigin.y);
}
// clip the DC to avoid overwriting the non client area
SetClippingRegion(wxPoint(0, 0), m_canvas->GetClientSize());
#endif // __WXUNIVERSAL__
} // end of wxClientDC::InitDC
wxClientDC::~wxClientDC()
{
} // end of wxClientDC::~wxClientDC
// ----------------------------------------------------------------------------
// wxPaintDC
// ----------------------------------------------------------------------------