[Libreoffice-commits] core.git: Branch 'distro/collabora/co-2021' - sw/source
Miklos Vajna (via logerrit)
logerrit at kemper.freedesktop.org
Wed Aug 4 16:33:52 UTC 2021
sw/source/core/view/viewsh.cxx | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
New commits:
commit d105babfb52e9ebfb0838e2846a48fd015ea92bf
Author: Miklos Vajna <vmiklos at collabora.com>
AuthorDate: Wed Aug 4 13:44:24 2021 +0200
Commit: Mike Kaganski <mike.kaganski at collabora.com>
CommitDate: Wed Aug 4 18:33:17 2021 +0200
sw lok: avoid expensive DLPre/PostPaint2() around InvalidateWindows()
This shows up on profiles and it's not needed. It was only there,
because Online always needs an invalidation to have updated tiles, so
there the paint was replaced with an invalidate. And then the
drawinglayer setup/teardown was not made conditional by accident.
The PaintTile() case goes via Paint() -> PaintSwFrame(), which still
calls these functions; this commit only speeds up
SwViewShell::ImplEndAction(), which is called synchronously e.g. on
every keypress.
(cherry picked from commit aff28c59816d046d9b74460c1b17101b99b9514e)
Change-Id: I6c362f148bc2837bd842602754770c5267e16afd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120002
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Mike Kaganski <mike.kaganski at collabora.com>
diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx
index ef34c351b6c0..4276b4161482 100644
--- a/sw/source/core/view/viewsh.cxx
+++ b/sw/source/core/view/viewsh.cxx
@@ -409,7 +409,10 @@ void SwViewShell::ImplEndAction( const bool bIdleEnd )
// 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 (!comphelper::LibreOfficeKit::isActive())
+ {
+ DLPrePaint2(vcl::Region(aRect.SVRect()));
+ }
if ( bPaintsFromSystem )
PaintDesktop(*GetOut(), aRect);
@@ -419,7 +422,10 @@ void SwViewShell::ImplEndAction( const bool bIdleEnd )
pCurrentLayout->GetCurrShell()->InvalidateWindows(aRect.SVRect());
// #i75172# end DrawingLayer paint
- DLPostPaint2(true);
+ if (!comphelper::LibreOfficeKit::isActive())
+ {
+ DLPostPaint2(true);
+ }
}
}
More information about the Libreoffice-commits
mailing list