[Libreoffice-commits] core.git: sd/source
Pranam Lashkari (via logerrit)
logerrit at kemper.freedesktop.org
Sat Oct 31 08:52:51 UTC 2020
sd/source/ui/view/drviews2.cxx | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
New commits:
commit 950cc4b9947f2b8d230c739432e2a6729a79ab67
Author: Pranam Lashkari <lpranam at collabora.com>
AuthorDate: Tue Oct 6 18:53:34 2020 +0530
Commit: Pranam Lashkari <lpranam at collabora.com>
CommitDate: Sat Oct 31 09:52:17 2020 +0100
fixed crashing on duplicating slide if slide pan is not visible
Change-Id: I30cdc8365d0a31b408dc4eb18b195703837c838a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104027
Tested-by: Andras Timar <andras.timar at collabora.com>
Reviewed-by: Andras Timar <andras.timar at collabora.com>
(cherry picked from commit 494cee664a3b3dc64dc83e1c29b17097d184a2d7)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104684
Tested-by: Jenkins
Reviewed-by: Pranam Lashkari <lpranam at collabora.com>
diff --git a/sd/source/ui/view/drviews2.cxx b/sd/source/ui/view/drviews2.cxx
index 411b377b3141..279eb753af57 100644
--- a/sd/source/ui/view/drviews2.cxx
+++ b/sd/source/ui/view/drviews2.cxx
@@ -766,10 +766,17 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
case SID_DUPLICATE_PAGE:
{
- DuplicateSelectedSlides(rReq);
+ auto slideSorter = sd::slidesorter::SlideSorterViewShell::GetSlideSorter(GetViewShellBase());
+ SdPage* pNewPage = nullptr;
+ if(slideSorter)
+ DuplicateSelectedSlides(rReq);
+ else
+ pNewPage = CreateOrDuplicatePage (rReq, mePageKind, GetActualPage());
Cancel();
if(HasCurrentFunction(SID_BEZIER_EDIT) )
GetViewFrame()->GetDispatcher()->Execute(SID_OBJECT_SELECT, SfxCallMode::ASYNCHRON);
+ if(!slideSorter && pNewPage != nullptr)
+ SwitchPage((pNewPage->GetPageNum()-1)/2);
rReq.Done();
}
break;
More information about the Libreoffice-commits
mailing list