Applied patch [ 603104 ] wxX11 wxClientDC, wxPaintDC fix

This patch changes a pre-compile check to a run-time
check. The fix is that for windows that only using 1 X
window (like wxFrame) the client area needs to be
adjusted...

FL is one of the things that needs this patch to work ok
under wxX11.

Hans Van Leemputten


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16911 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2002-09-01 15:59:22 +00:00
parent 5a33bc097f
commit 7948c0c244

View File

@@ -2046,13 +2046,14 @@ wxClientDC::wxClientDC( wxWindow *window )
m_window = (WXWindow*) window->GetClientAreaWindow();
#if wxUSE_TWO_WINDOWS
#else
// Adjust the client area when the wxWindow is not using 2 X windows.
if (m_window == (WXWindow*) window->GetMainWindow())
{
wxPoint ptOrigin = window->GetClientAreaOrigin();
SetDeviceOrigin(ptOrigin.x, ptOrigin.y);
wxSize size = window->GetClientSize();
SetClippingRegion(wxPoint(0, 0), size);
#endif
}
}
void wxClientDC::DoGetSize(int *width, int *height) const