diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-07-08 15:33:58 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-07-08 16:43:41 +0100 |
commit | ddc6fe92a6d0b8f85260a25d7097ec821c4b54db (patch) | |
tree | ece7648a3e655ce193cf57d2f6c735804906018d /vcl | |
parent | 56f79350d2556d4c8336e768f33d02423b0a9fbb (diff) |
ScrollFlags::NoInvalidate is never set
Change-Id: I7646b9572429540704a6f84734f647c10540825d
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/window/paint.cxx | 46 |
1 files changed, 21 insertions, 25 deletions
diff --git a/vcl/source/window/paint.cxx b/vcl/source/window/paint.cxx index a483d8d09fd9..dafc4aa22125 100644 --- a/vcl/source/window/paint.cxx +++ b/vcl/source/window/paint.cxx @@ -1563,35 +1563,31 @@ void Window::ImplScroll( const Rectangle& rRect, // adapt paint areas ImplMoveAllInvalidateRegions( aRectMirror, nHorzScroll, nVertScroll, bScrollChildren ); - if ( !(nFlags & ScrollFlags::NoInvalidate) ) - { - ImplCalcOverlapRegion( aRectMirror, aInvalidateRegion, !bScrollChildren, false ); - - // --- RTL --- - // if the scrolling on the device is performed in the opposite direction - // then move the overlaps in that direction to compute the invalidate region - // on the correct side, i.e., revert nHorzScroll - - if ( !aInvalidateRegion.IsEmpty() ) - { - aInvalidateRegion.Move( bReMirror ? -nHorzScroll : nHorzScroll, nVertScroll ); - bErase = true; - } + ImplCalcOverlapRegion( aRectMirror, aInvalidateRegion, !bScrollChildren, false ); - Rectangle aDestRect(aRectMirror); - aDestRect.Move(bReMirror ? -nHorzScroll : nHorzScroll, nVertScroll); - vcl::Region aWinInvalidateRegion(aRectMirror); - if (!SupportsDoubleBuffering()) - { - // There will be no CopyArea() call below, so invalidate the - // whole visible area, not only the smaller one that was just - // scrolled in. - aWinInvalidateRegion.Exclude(aDestRect); - } + // --- RTL --- + // if the scrolling on the device is performed in the opposite direction + // then move the overlaps in that direction to compute the invalidate region + // on the correct side, i.e., revert nHorzScroll + if (!aInvalidateRegion.IsEmpty()) + { + aInvalidateRegion.Move(bReMirror ? -nHorzScroll : nHorzScroll, nVertScroll); + bErase = true; + } - aInvalidateRegion.Union( aWinInvalidateRegion ); + Rectangle aDestRect(aRectMirror); + aDestRect.Move(bReMirror ? -nHorzScroll : nHorzScroll, nVertScroll); + vcl::Region aWinInvalidateRegion(aRectMirror); + if (!SupportsDoubleBuffering()) + { + // There will be no CopyArea() call below, so invalidate the + // whole visible area, not only the smaller one that was just + // scrolled in. + aWinInvalidateRegion.Exclude(aDestRect); } + aInvalidateRegion.Union(aWinInvalidateRegion); + Point aPoint( mnOutOffX, mnOutOffY ); vcl::Region aRegion( Rectangle( aPoint, Size( mnOutWidth, mnOutHeight ) ) ); if ( nFlags & ScrollFlags::Clip ) |