sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)
New commits: commit 5f7987cef5133d7207b09c0c523289bff06f6241 Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Fri Dec 13 12:47:54 2019 +0000 Commit: Xisco Faulí <xiscofa...@libreoffice.org> CommitDate: Fri Dec 13 19:24:22 2019 +0100 Resolves: tdf#129346 if nothing currently selected, select something in the slidesorter Change-Id: I66853ba56eab93dfb18de7496212eb64e97cd2bf Reviewed-on: https://gerrit.libreoffice.org/85109 Tested-by: Jenkins Reviewed-by: Xisco Faulí <xiscofa...@libreoffice.org> diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx b/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx index 0d4b23ff8dfe..bacf5fdf0323 100644 --- a/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx +++ b/sd/source/ui/slidesorter/controller/SlsSelectionObserver.cxx @@ -112,7 +112,7 @@ void SelectionObserver::EndObservation() PageSelector& rSelector (mrSlideSorter.GetController().GetPageSelector()); PageSelector::UpdateLock aUpdateLock (mrSlideSorter); rSelector.DeselectAllPages(); - if ( ! maInsertedPages.empty()) + if (!maInsertedPages.empty()) { // Select the inserted pages. for (const auto& rpPage : maInsertedPages) @@ -121,6 +121,12 @@ void SelectionObserver::EndObservation() } maInsertedPages.clear(); } + else + { + // tdf#129346 nothing currently selected, select something, if possible + if (rSelector.GetPageCount()) + rSelector.SelectPage(0); + } aUpdateLock.Release(); mrSlideSorter.GetController().GetFocusManager().SetFocusedPageToCurrentPage(); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits