diff options
author | Michael Stahl <mstahl@redhat.com> | 2013-06-24 19:05:45 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-06-27 19:12:18 +0000 |
commit | 435be554c5025f2309c016170d5225ac086c727b (patch) | |
tree | d78cab0a617e5ceb830d00e3d9995c0fde88013b | |
parent | 31a53b30b040021e503f779fd63d62ef723d82b0 (diff) |
fdo#60444: Revert "fdo#58029 - substantially accelerate re-rendering..."
This reverts commit 6c98ad71478cb72b51634b32d6e553ccaec30190.
This breaks selection of transparent form controls (fdo#60444), because
the Update method is not called on the children.
Change-Id: Id0b6a34a15aa1ed7bd5aa0d7b5626e60bee57e30
(cherry picked from commit f022f39638fbe970f1b839c757dcccd3baa69445)
Reviewed-on: https://gerrit.libreoffice.org/4490
Reviewed-by: Thorsten Behrens <tbehrens@suse.com>
Tested-by: Thorsten Behrens <tbehrens@suse.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | svx/source/sdr/overlay/overlaymanagerbuffered.cxx | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/svx/source/sdr/overlay/overlaymanagerbuffered.cxx b/svx/source/sdr/overlay/overlaymanagerbuffered.cxx index 6b394bef5ebe..64ac99d1f565 100644 --- a/svx/source/sdr/overlay/overlaymanagerbuffered.cxx +++ b/svx/source/sdr/overlay/overlaymanagerbuffered.cxx @@ -348,15 +348,28 @@ namespace sdr if(bTargetIsWindow) { Window& rWindow = static_cast< Window& >(rmOutputDevice); - if(rWindow.IsChildTransparentModeEnabled()) + + if(rWindow.IsChildTransparentModeEnabled() && rWindow.GetChildCount()) { - // Get VCL to invalidate it's children - more efficiently. fdo#58029 const Rectangle aRegionRectanglePixel( maBufferRememberedRangePixel.getMinX(), maBufferRememberedRangePixel.getMinY(), maBufferRememberedRangePixel.getMaxX(), maBufferRememberedRangePixel.getMaxY()); - rWindow.Invalidate(aRegionRectanglePixel, - INVALIDATE_NOTRANSPARENT|INVALIDATE_CHILDREN|INVALIDATE_UPDATE); + for(sal_uInt16 a(0); a < rWindow.GetChildCount(); a++) + { + Window* pCandidate = rWindow.GetChild(a); + + if(pCandidate && pCandidate->IsPaintTransparent()) + { + const Rectangle aCandidatePosSizePixel(pCandidate->GetPosPixel(), pCandidate->GetSizePixel()); + + if(aCandidatePosSizePixel.IsOver(aRegionRectanglePixel)) + { + pCandidate->Invalidate(INVALIDATE_NOTRANSPARENT|INVALIDATE_CHILDREN); + pCandidate->Update(); + } + } + } } } |