summaryrefslogtreecommitdiff
path: root/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2018-11-06 11:20:27 +0100
committerJan Holesovsky <kendy@collabora.com>2018-11-06 17:35:06 +0100
commitdf4f2b117d5925fa9e1fa4f9b3aec424022a583f (patch)
tree40c6d919706638387a7c5fb031738e60e2fae825 /sfx2/source/sidebar/ContextChangeBroadcaster.cxx
parent28a698db6f604137443053144dde94c9e553c0ef (diff)
lok: Notify about the current editing context.
Change-Id: I47e67b680a6abdb66020b295f55ee6a73b7b5608 Reviewed-on: https://gerrit.libreoffice.org/62956 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Diffstat (limited to 'sfx2/source/sidebar/ContextChangeBroadcaster.cxx')
-rw-r--r--sfx2/source/sidebar/ContextChangeBroadcaster.cxx10
1 files changed, 10 insertions, 0 deletions
diff --git a/sfx2/source/sidebar/ContextChangeBroadcaster.cxx b/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
index 716cb84fcfc4..3a182d14f368 100644
--- a/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
+++ b/sfx2/source/sidebar/ContextChangeBroadcaster.cxx
@@ -22,7 +22,10 @@
#include <com/sun/star/ui/ContextChangeEventMultiplexer.hpp>
#include <com/sun/star/frame/ModuleManager.hpp>
#include <osl/diagnose.h>
+#include <comphelper/lok.hxx>
#include <comphelper/processfactory.hxx>
+#include <sfx2/lokhelper.hxx>
+#include <sfx2/viewsh.hxx>
using namespace css;
using namespace css::uno;
@@ -86,6 +89,13 @@ void ContextChangeBroadcaster::BroadcastContextChange (
return;
}
+ // notify the LOK too
+ if (comphelper::LibreOfficeKit::isActive())
+ {
+ if (SfxViewShell* pViewShell = SfxViewShell::Get(rxFrame->getController()))
+ SfxLokHelper::notifyContextChange(pViewShell, rsModuleName, rsContextName);
+ }
+
const css::ui::ContextChangeEventObject aEvent(
rxFrame->getController(),
rsModuleName,