[Libreoffice-commits] core.git: sc/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Sun May 17 18:51:22 UTC 2020
sc/source/ui/navipi/content.cxx | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
New commits:
commit b9e635d6a9f52edefd9d53b8feb68768381890e4
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Sat May 16 20:41:20 2020 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Sun May 17 20:50:39 2020 +0200
tdf#133079 ensure Sheet root is selected if nothing else would be
Change-Id: I01d45bfa8f410dcf35a9ecc90b295b7c75ccc746
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94369
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/sc/source/ui/navipi/content.cxx b/sc/source/ui/navipi/content.cxx
index 8b25b86de75f..edb574513b52 100644
--- a/sc/source/ui/navipi/content.cxx
+++ b/sc/source/ui/navipi/content.cxx
@@ -1568,7 +1568,15 @@ void ScContentTree::ApplyNavigatorSettings()
if( pSettings )
{
ScContentId nRootSel = pSettings->GetRootSelected();
- sal_uLong nChildSel = pSettings->GetChildSelected();
+ auto nChildSel = pSettings->GetChildSelected();
+
+ // tdf#133079 ensure Sheet root is selected if nothing
+ // else would be
+ if (nRootSel == ScContentId::ROOT)
+ {
+ nRootSel = ScContentId::TABLE;
+ nChildSel = SC_CONTENT_NOCHILD;
+ }
for( int i = 1; i <= int(ScContentId::LAST); ++i )
{
More information about the Libreoffice-commits
mailing list