Kaydet (Commit) a56cda35 authored tarafından Miklos Vajna's avatar Miklos Vajna Kaydeden (comit) Caolán McNamara

tdf#93096 sw: fix selection with keyboard outside current view

Regression from commit c9175a1b
(SwViewShell::ImplEndAction: avoid direct PaintDesktop(), 2015-07-03),
the problem is that while going via InvalidateWindows() is fine for the
double-buffering case, it has side effects when painting directly, so
revert back to the old code in that case.

Change-Id: Ib1e3b143f5cfe2c6ab8b102a1a2064900282f136
(cherry picked from commit 222f10e7)
Reviewed-on: https://gerrit.libreoffice.org/17835Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst 78a7dfe3
...@@ -405,7 +405,25 @@ void SwViewShell::ImplEndAction( const bool bIdleEnd ) ...@@ -405,7 +405,25 @@ void SwViewShell::ImplEndAction( const bool bIdleEnd )
} }
if ( bPaint ) if ( bPaint )
{ {
InvalidateWindows(aRect.SVRect()); if (GetWin() && GetWin()->SupportsDoubleBuffering())
InvalidateWindows(aRect.SVRect());
else
{
// #i75172# begin DrawingLayer paint
// need to do begin/end DrawingLayer preparation for each single rectangle of the
// repaint region. I already tried to prepare only once for the whole Region. This
// seems to work (and does technically) but fails with transparent objects. Since the
// region given to BeginDarwLayers() defines the clip region for DrawingLayer paint,
// transparent objects in the single rectangles will indeed be painted multiple times.
DLPrePaint2(vcl::Region(aRect.SVRect()));
if ( bPaintsFromSystem )
PaintDesktop(*GetOut(), aRect);
pCurrentLayout->GetCurrShell()->InvalidateWindows(aRect.SVRect());
// #i75172# end DrawingLayer paint
DLPostPaint2(true);
}
} }
else else
lcl_PaintTransparentFormControls(*this, aRect); // i#107365 lcl_PaintTransparentFormControls(*this, aRect); // i#107365
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment