summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorSzymon Kłos <szymon.klos@collabora.com>2021-06-08 15:28:41 +0200
committerSzymon Kłos <szymon.klos@collabora.com>2021-06-10 11:05:10 +0200
commit8e03875ca77e4e3adf13373a5ed2935eef56283f (patch)
tree9bac7249bddd5dd48d2e07c7e0a6daa6f70067c4 /sfx2
parentfaa94e959ff1bb92c26bf305e4c536786f043858 (diff)
jsdialog: sidebar: dump visibility state for widgets
we need this to build all the widgets on the client side and alow then show/hide widgets Change-Id: Ib3d8fc673cc787925e19a6e9df673e923ed7ecef Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116841 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com>
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/sidebar/Deck.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/sfx2/source/sidebar/Deck.cxx b/sfx2/source/sidebar/Deck.cxx
index 7a5b89139a08..35203a18c4cd 100644
--- a/sfx2/source/sidebar/Deck.cxx
+++ b/sfx2/source/sidebar/Deck.cxx
@@ -136,10 +136,12 @@ void Deck::Resize()
*/
void Deck::DumpAsPropertyTree(tools::JsonWriter& rJsonWriter)
{
- rJsonWriter.put("id", get_id()); // TODO could be missing - sort out
+ rJsonWriter.put("id", get_id() != "" ? get_id() : msId);
rJsonWriter.put("type", "deck");
rJsonWriter.put("text", GetText());
rJsonWriter.put("enabled", IsEnabled());
+ if (!IsVisible())
+ rJsonWriter.put("visible", false);
auto childrenNode = rJsonWriter.startArray("children");
for (auto &it : maPanels)