diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-08-04 11:37:34 +0200 |
---|---|---|
committer | Michael Meeks <michael.meeks@collabora.com> | 2021-09-16 19:01:07 +0200 |
commit | 712c5d7090abea828aff57f199879a7897211680 (patch) | |
tree | d2e24d74769c1fbc8cd448bbcb4a15169cc44519 /include | |
parent | d65e177242f2e7359e17161af5f5092daacc34eb (diff) |
improve LOK notifyInvalidation
(*) tweak buffer in SfxLokHelper::notifyInvalidation to be a bit larger,
so we avoid the cost of a resize©
(*) use our optimised OString concatentation instead of going via
std::stringstream
(*) pass down a pointer to rectangle, instead of a string. later we will
use this to avoid doing the stringify until later
Change-Id: Ia3e3042bc919d9b9cb80e47a93704eb236438605
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119994
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120072
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
(cherry picked from commit 417f881d20cafe88a02b64894ba4483875fb9460)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122123
Diffstat (limited to 'include')
-rw-r--r-- | include/sfx2/lokhelper.hxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/sfx2/lokhelper.hxx b/include/sfx2/lokhelper.hxx index 07baf8a20a3c..390b024757cf 100644 --- a/include/sfx2/lokhelper.hxx +++ b/include/sfx2/lokhelper.hxx @@ -15,6 +15,7 @@ #include <vcl/event.hxx> #include <sfx2/dllapi.h> #include <sfx2/viewsh.hxx> +#include <tools/gen.hxx> #include <cstddef> #include <rtl/string.hxx> #include <optional> @@ -107,7 +108,7 @@ public: /// Emits a LOK_CALLBACK_DOCUMENT_SIZE_CHANGED for all views of the same document - if @bInvalidateAll - first invalidates all parts static void notifyDocumentSizeChangedAllViews(vcl::ITiledRenderable* pDoc, bool bInvalidateAll = true); /// Emits a LOK_CALLBACK_INVALIDATE_TILES, but tweaks it according to setOptionalFeatures() if needed. - static void notifyInvalidation(SfxViewShell const* pThisView, const OString& rPayload); + static void notifyInvalidation(SfxViewShell const* pThisView, tools::Rectangle const *); /// Emits a LOK_CALLBACK_INVALIDATE_VISIBLE_CURSOR, but tweaks it according to setOptionalFeatures() if needed. static void notifyVisCursorInvalidation(OutlinerViewShell const* pThisView, const OString& rRectangle, bool bMispelledWord = false, const OString& rHyperlink = ""); /// Notifies all views with the given type and payload. |