summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Raykowski <raykowj@gmail.com>2021-12-23 20:46:59 -0900
committerXisco Fauli <xiscofauli@libreoffice.org>2021-12-27 12:33:45 +0100
commitf0ae7571b7f0d8b03f6c365d6c24ee69d973c781 (patch)
treecc279d0419895c14b1c3c369c88f9680f9670bad
parentbe5e8e00ce08a7386b0c2ad223e4df16195313fe (diff)
tdf#146003 tdf#106613 Draw: fix slide rename not updated in Navigator
Change-Id: Iee2d34e3192e3f7875ab10f3e79e9dc1a2fb20b8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127397 Tested-by: Jenkins Reviewed-by: Jim Raykowski <raykowj@gmail.com> (cherry picked from commit 9bfc42015acd6ae3475ab7927ccc006507cc38a2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/127486 Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
-rw-r--r--sd/source/ui/slidesorter/controller/SlsSlotManager.cxx9
-rw-r--r--sd/source/ui/view/drviewsb.cxx8
-rw-r--r--sd/source/ui/view/drviewsd.cxx3
3 files changed, 8 insertions, 12 deletions
diff --git a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
index 89d10e310725..8ade9b296462 100644
--- a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
@@ -1029,12 +1029,9 @@ bool SlotManager::RenameSlideFromDrawViewShell( sal_uInt16 nPageId, const OUStri
pDocument->SetChanged();
// inform navigator about change
- SfxBoolItem aItem( SID_NAVIGATOR_INIT, true );
- if (mrSlideSorter.GetViewShell() != nullptr)
- mrSlideSorter.GetViewShell()->GetDispatcher()->ExecuteList(
- SID_NAVIGATOR_INIT,
- SfxCallMode::ASYNCHRON | SfxCallMode::RECORD,
- { &aItem });
+ if (mrSlideSorter.GetViewShell() && mrSlideSorter.GetViewShell()->GetViewFrame())
+ mrSlideSorter.GetViewShell()->GetViewFrame()->GetBindings().Invalidate(
+ SID_NAVIGATOR_STATE, true);
}
return bSuccess;
diff --git a/sd/source/ui/view/drviewsb.cxx b/sd/source/ui/view/drviewsb.cxx
index 5bc741c91269..6f6bba8555d5 100644
--- a/sd/source/ui/view/drviewsb.cxx
+++ b/sd/source/ui/view/drviewsb.cxx
@@ -97,9 +97,11 @@ bool DrawViewShell::RenameSlide( sal_uInt16 nPageId, const OUString & rName )
GetDoc()->SetChanged();
// inform navigator about change
- SfxBoolItem aItem( SID_NAVIGATOR_INIT, true );
- GetViewFrame()->GetDispatcher()->ExecuteList(SID_NAVIGATOR_INIT,
- SfxCallMode::ASYNCHRON | SfxCallMode::RECORD, { &aItem });
+ if (GetViewFrame())
+ {
+ SfxBindings& rBindings = GetViewFrame()->GetBindings();
+ rBindings.Invalidate(SID_NAVIGATOR_STATE, true);
+ }
// Tell the slide sorter about the name change (necessary for
// accessibility.)
diff --git a/sd/source/ui/view/drviewsd.cxx b/sd/source/ui/view/drviewsd.cxx
index 763ae13eac91..0926e02990e5 100644
--- a/sd/source/ui/view/drviewsd.cxx
+++ b/sd/source/ui/view/drviewsd.cxx
@@ -61,9 +61,6 @@ void DrawViewShell::ExecNavigatorWin( SfxRequest& rReq )
if( pNavWin )
pNavWin->InitTreeLB( GetDoc() );
}
- SfxBindings& rBindings = GetViewFrame()->GetBindings();
- rBindings.Invalidate(SID_NAVIGATOR_STATE, true);
- rBindings.Invalidate(SID_NAVIGATOR_PAGENAME, true);
}
break;