summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorSzymon Kłos <szymon.klos@collabora.com>2018-11-06 09:43:11 +0100
committerMichael Meeks <michael.meeks@collabora.com>2019-09-24 21:18:00 +0200
commit240ec23841cc1e9728f9273d88c1f9a170cf3fb8 (patch)
tree1e0d2ce5b7a70e858882a6cb4bed5bd9eabd0158 /sc
parent56b078502b6554e6a53dc30eb3098a6f3d6b9a7c (diff)
Keep reference mode if only one dialog closed
Change-Id: I9cf7988da7f83c28a0919c69ace131ee93054486 Reviewed-on: https://gerrit.libreoffice.org/79466 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/app/scmod.cxx19
1 files changed, 17 insertions, 2 deletions
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx
index d8eb515e8eda..e21a83310256 100644
--- a/sc/source/ui/app/scmod.cxx
+++ b/sc/source/ui/app/scmod.cxx
@@ -1483,7 +1483,16 @@ void ScModule::SetRefDialog( sal_uInt16 nId, bool bVis, SfxViewFrame* pViewFrm )
//if ( pViewFrm )
// pViewFrm->GetBindings().Update(); // to avoid trouble in LockDispatcher
- m_nCurRefDlgId = bVis ? nId : 0 ; // before SetChildWindow
+ // before SetChildWindow
+ if ( comphelper::LibreOfficeKit::isActive() )
+ {
+ if ( bVis )
+ m_nCurRefDlgId = nId;
+ }
+ else
+ {
+ m_nCurRefDlgId = bVis ? nId : 0;
+ }
if ( pViewFrm )
{
@@ -1753,7 +1762,13 @@ void ScModule::EndReference()
//FIXME: ShowRefFrame at InputHdl, if the Function AutoPilot is open?
if ( m_nCurRefDlgId )
{
- SfxChildWindow* pChildWnd = lcl_GetChildWinFromAnyView( m_nCurRefDlgId );
+ SfxChildWindow* pChildWnd = nullptr;
+
+ if ( comphelper::LibreOfficeKit::isActive() )
+ pChildWnd = lcl_GetChildWinFromCurrentView( m_nCurRefDlgId );
+ else
+ pChildWnd = lcl_GetChildWinFromAnyView( m_nCurRefDlgId );
+
OSL_ENSURE( pChildWnd, "NoChildWin" );
if ( pChildWnd )
{