sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
New commits: commit ea574f7929d4c226d56273178779ef38ca2ce5c9 Author: Andreas Heinisch <andreas.heini...@yahoo.de> AuthorDate: Fri Oct 6 09:27:10 2023 +0200 Commit: Andreas Heinisch <andreas.heini...@yahoo.de> CommitDate: Mon Oct 23 18:44:30 2023 +0200 tdf#111737 - Add new (master) page depending on the edit mode Change-Id: I5e0d0f604714cbc395cd6b0c7a9b5665f0d5f93b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157631 Tested-by: Jenkins Reviewed-by: Andreas Heinisch <andreas.heini...@yahoo.de> diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx index f8376ec409fd..1af2abcabfc7 100644 --- a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx +++ b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx @@ -377,8 +377,11 @@ bool SelectionFunction::KeyInput (const KeyEvent& rEvent) } else if (pViewShell->GetDispatcher() != nullptr) { + // tdf#111737 - add new (master) page depending on the edit mode pViewShell->GetDispatcher()->Execute( - SID_INSERTPAGE, + mrSlideSorter.GetModel().GetEditMode() == EditMode::Page + ? SID_INSERTPAGE + : SID_INSERT_MASTER_PAGE, SfxCallMode::ASYNCHRON | SfxCallMode::RECORD); } bResult = true;