[Libreoffice-commits] core.git: sw/source
Miklos Vajna
vmiklos at collabora.co.uk
Fri Jun 10 10:15:44 UTC 2016
sw/source/core/view/viewsh.cxx | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
New commits:
commit 5cf68b0eac1a81ebcb2fa8f0e90fc4f7e350bd3a
Author: Miklos Vajna <vmiklos at collabora.co.uk>
Date: Fri Jun 10 11:14:03 2016 +0200
sw: implement per-view LOK_CALLBACK_DOCUMENT_SIZE_CHANGED
This is interesting for all views, but given we invoke the callback in
SwViewShell, it's only necessary to notify the matching LOK view
callback and still all views are updated.
Change-Id: Idc59b2bba1a944a9ad1dd0acd934a85130b32993
Reviewed-on: https://gerrit.libreoffice.org/26154
Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
Tested-by: Jenkins <ci at libreoffice.org>
diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx
index 319b4ac..832283f 100644
--- a/sw/source/core/view/viewsh.cxx
+++ b/sw/source/core/view/viewsh.cxx
@@ -1026,7 +1026,10 @@ void SwViewShell::SizeChgNotify()
std::stringstream ss;
ss << aDocSize.Width() + 2L * DOCUMENTBORDER << ", " << aDocSize.Height() + 2L * DOCUMENTBORDER;
OString sRect = ss.str().c_str();
- libreOfficeKitCallback(LOK_CALLBACK_DOCUMENT_SIZE_CHANGED, sRect.getStr());
+ if (comphelper::LibreOfficeKit::isViewCallback())
+ GetSfxViewShell()->libreOfficeKitViewCallback(LOK_CALLBACK_DOCUMENT_SIZE_CHANGED, sRect.getStr());
+ else
+ libreOfficeKitCallback(LOK_CALLBACK_DOCUMENT_SIZE_CHANGED, sRect.getStr());
}
}
}
More information about the Libreoffice-commits
mailing list