summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2016-07-15 17:26:34 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2016-07-15 18:07:44 +0200
commitbc9b4fd4c83af3532204237157821d4884c42d8e (patch)
tree7f64935ee980f5a5474f4db876c844e8e263ac6e /sc
parent85c5a172953ac29d1fcab3f4c2f19fa897074e52 (diff)
lok::Document::destroyView: clean up view cursors/selections
Change-Id: Icd3f96a922e7d1aec0d52e90df87ec45790c9807
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/view/tabvwsh4.cxx8
1 files changed, 8 insertions, 0 deletions
diff --git a/sc/source/ui/view/tabvwsh4.cxx b/sc/source/ui/view/tabvwsh4.cxx
index 51837a3c443d..b2fdbdea9daa 100644
--- a/sc/source/ui/view/tabvwsh4.cxx
+++ b/sc/source/ui/view/tabvwsh4.cxx
@@ -97,6 +97,8 @@
#include <com/sun/star/chart2/XCoordinateSystem.hpp>
#include <com/sun/star/chart2/XChartTypeContainer.hpp>
#include <com/sun/star/chart2/XChartType.hpp>
+#include <sfx2/lokhelper.hxx>
+#include <LibreOfficeKit/LibreOfficeKitEnums.h>
extern SfxViewShell* pScActiveViewShell; // global.cxx
@@ -1735,6 +1737,12 @@ ScTabViewShell::ScTabViewShell( SfxViewFrame* pViewFrame,
ScTabViewShell::~ScTabViewShell()
{
+ // Notify other LOK views that we are going away.
+ SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_VIEW_CURSOR_VISIBLE, "visible", "false");
+ SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_TEXT_VIEW_SELECTION, "selection", "");
+ SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_GRAPHIC_VIEW_SELECTION, "selection", "EMPTY");
+ SfxLokHelper::notifyOtherViews(this, LOK_CALLBACK_CELL_VIEW_CURSOR, "rectangle", "EMPTY");
+
ScDocShell* pDocSh = GetViewData().GetDocShell();
EndListening(*pDocSh);
EndListening(*GetViewFrame());