[Libreoffice-commits] online.git: kit/ChildSession.cpp
Michael Meeks (via logerrit)
logerrit at kemper.freedesktop.org
Sat Nov 30 22:02:06 UTC 2019
kit/ChildSession.cpp | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
New commits:
commit 8bb64b6554b45fff8e4f47629123bf95822c46e1
Author: Michael Meeks <michael.meeks at collabora.com>
AuthorDate: Sat Nov 30 17:15:45 2019 +0000
Commit: Michael Meeks <michael.meeks at collabora.com>
CommitDate: Sat Nov 30 23:01:48 2019 +0100
lok: add viewId to window painting, to allow special-casing on render.
View switching should not cause the sidebar UX to re-build at all. So
pass the view-id into the render call so we can avoid this.
Change-Id: I194c1841df2cedfcdf82defb2712d20715d7ff1d
Reviewed-on: https://gerrit.libreoffice.org/84131
Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
Tested-by: Michael Meeks <michael.meeks at collabora.com>
diff --git a/kit/ChildSession.cpp b/kit/ChildSession.cpp
index e254b94de..d07125a5c 100644
--- a/kit/ChildSession.cpp
+++ b/kit/ChildSession.cpp
@@ -1472,8 +1472,6 @@ bool ChildSession::renderWindow(const char* /*buffer*/, int /*length*/, const st
{
const unsigned winId = (tokens.size() > 1 ? std::stoul(tokens[1]) : 0);
- getLOKitDocument()->setView(_viewId);
-
int startX = 0, startY = 0;
int bufferWidth = 800, bufferHeight = 600;
double dpiScale = 1.0;
@@ -1502,7 +1500,7 @@ bool ChildSession::renderWindow(const char* /*buffer*/, int /*length*/, const st
int width = bufferWidth, height = bufferHeight;
std::string response;
const auto start = std::chrono::system_clock::now();
- getLOKitDocument()->paintWindow(winId, pixmap.data(), startX, startY, width, height, dpiScale);
+ getLOKitDocument()->paintWindow(winId, pixmap.data(), startX, startY, width, height, dpiScale, _viewId);
const double area = width * height;
const auto duration = std::chrono::system_clock::now() - start;
More information about the Libreoffice-commits
mailing list