X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ab6b6b15e0790bf3fd9e5b58da7077ac5592d8d3..ccdcde00d9ae27ca20ff6c3c9495918a0ec725aa:/src/univ/winuniv.cpp diff --git a/src/univ/winuniv.cpp b/src/univ/winuniv.cpp index be8a2ba4e3..9662665813 100644 --- a/src/univ/winuniv.cpp +++ b/src/univ/winuniv.cpp @@ -265,10 +265,14 @@ void wxWindow::OnPaint(wxPaintEvent& event) bool wxWindow::DoDrawBackground(wxDC& dc) { - // FIXME: leaving this code in leads to partial bg redraws sometimes under - // MSW + // FIXME: Leaving this code in leads to partial bg redraws + // sometimes under MSW. + // The same happens under X11 because it has a clear + // region and an update region and these are sometimes + // different. RR. wxRect rect; -#ifndef __WXMSW__ +// #ifndef __WXMSW__ +#if 0 rect = GetUpdateRegion().GetBox(); if ( !rect.width && !rect.height ) #endif @@ -298,7 +302,7 @@ bool wxWindow::DoDrawBackground(wxDC& dc) void wxWindow::EraseBackground(wxDC& dc, const wxRect& rect) { // TODO: handle bg bitmaps here! - + m_renderer->DrawBackground(dc, wxTHEME_BG_COLOUR(this), rect, GetStateFlags()); } @@ -843,8 +847,12 @@ void wxWindow::SetScrollbar(int orient, // give the window a chance to relayout if ( hasClientSizeChanged ) { +#if wxUSE_TWO_WINDOWS + wxWindowNative::SetSize( GetSize() ); +#else wxSizeEvent event(GetSize()); (void)GetEventHandler()->ProcessEvent(event); +#endif } }