summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorSzymon Kłos <szymon.klos@collabora.com>2020-12-10 15:35:53 +0100
committerAndras Timar <andras.timar@collabora.com>2021-04-07 20:28:31 +0200
commit788488a2a02204a5fd70620384eb00e2ac0aa9f3 (patch)
treefdfa2d9241223bbcc15514877dc957fa05178ad4 /vcl
parent7f5db2b6097b965efc2dc2ae8ef19e2b4b9beac6 (diff)
jsdialog: export dialog id
Change-Id: I406d64ec8e19661ab258908e29245bc7da245b7b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107558 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Szymon Kłos <szymon.klos@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108408 Tested-by: Szymon Kłos <szymon.klos@collabora.com>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/window/dialog.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx
index 8d84e4631ed9..e502c33caeb1 100644
--- a/vcl/source/window/dialog.cxx
+++ b/vcl/source/window/dialog.cxx
@@ -1640,6 +1640,11 @@ void Dialog::DumpAsPropertyTree(tools::JsonWriter& rJsonWriter)
if (!pActionArea->IsVisible())
rJsonWriter.put("collapsed", "true");
}
+
+ OUString sDialogId = OStringToOUString(GetHelpId(), RTL_TEXTENCODING_ASCII_US);
+ sal_Int32 nStartPos = sDialogId.lastIndexOf('/');
+ nStartPos = nStartPos >= 0 ? nStartPos + 1 : 0;
+ rJsonWriter.put("dialogid", sDialogId.copy(nStartPos));
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */