summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
authorMert Tumer <mert.tumer@collabora.com>2020-05-08 17:23:12 +0300
committerMert Tumer <mert.tumer@collabora.com>2020-08-04 12:44:31 +0200
commitff23d87cb00388095a94b90e061564fc179e1823 (patch)
tree49076df81dc933c80200fbf1b711400522049787 /desktop
parent87c58f6a9351f2a2ec40fd99c4e5a63bfe29d0b8 (diff)
mobile: fix calc chart wizard properties is not shown
Change-Id: I2fd98ddbdb529c3f224299c6824b4743797925be Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93747 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Andras Timar <andras.timar@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/97061 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/98248 Tested-by: Jenkins Reviewed-by: Mert Tumer <mert.tumer@collabora.com>
Diffstat (limited to 'desktop')
-rw-r--r--desktop/source/lib/init.cxx20
1 files changed, 16 insertions, 4 deletions
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 346c5174accd..db6dc07262a0 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -907,10 +907,24 @@ void setupSidebar(bool bShow, const OUString& sidebarDeckId = "")
if (!pDockingWin)
return;
+ OUString currentDeckId = pDockingWin->GetSidebarController()->GetCurrentDeckId();
+
+ // check if it is the chart deck id, if it is, don't switch to default deck
+ bool switchToDefault = true;
+
+ if (currentDeckId == "ChartDeck")
+ switchToDefault = false;
+
if (!sidebarDeckId.isEmpty())
{
pDockingWin->GetSidebarController()->SwitchToDeck(sidebarDeckId);
}
+ else
+ {
+ if (switchToDefault)
+ pDockingWin->GetSidebarController()->SwitchToDefaultDeck();
+ }
+
pDockingWin->SyncUpdate();
}
else
@@ -3750,7 +3764,6 @@ static void doc_postUnoCommand(LibreOfficeKitDocument* pThis, const char* pComma
SfxObjectShell* pDocSh = SfxObjectShell::Current();
OUString aCommand(pCommand, strlen(pCommand), RTL_TEXTENCODING_UTF8);
LibLODocument_Impl* pDocument = static_cast<LibLODocument_Impl*>(pThis);
- OUString sidebarDeckId = "PropertyDeck";
std::vector<beans::PropertyValue> aPropertyValuesVector(jsonToPropertyValuesVector(pArguments));
@@ -3906,13 +3919,12 @@ static void doc_postUnoCommand(LibreOfficeKitDocument* pThis, const char* pComma
}
else if (gImpl && aCommand == ".uno:LOKSidebarWriterPage")
{
- sidebarDeckId = "WriterPageDeck";
- setupSidebar(true, sidebarDeckId);
+ setupSidebar(true, "WriterPageDeck");
return;
}
else if (gImpl && aCommand == ".uno:SidebarShow")
{
- setupSidebar(true, sidebarDeckId);
+ setupSidebar(true);
return;
}
else if (gImpl && aCommand == ".uno:SidebarHide")