summaryrefslogtreecommitdiff
path: root/cui/source
diff options
context:
space:
mode:
authorMuhammet Kara <muhammet.kara@collabora.com>2021-05-23 11:22:57 +0300
committerHeiko Tietze <heiko.tietze@documentfoundation.org>2021-06-02 16:13:24 +0200
commit487dbbb69bfcf7c0368e9dc17e5aae1f17f8187f (patch)
tree2425ed9e8cc50e327881c73ee3257c82fb8f8032 /cui/source
parent89c01a87d55596f9c3b3c1ccabf7ef307edd9436 (diff)
tdf#116491: Customize: Add indication for experimental commands
Change-Id: Id485f86598aa89cbce6d742c0207c178e5208ee2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116014 Reviewed-by: Heiko Tietze <heiko.tietze@documentfoundation.org> Tested-by: Jenkins
Diffstat (limited to 'cui/source')
-rw-r--r--cui/source/customize/cfg.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index ef65977d3382..25f973016043 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -88,6 +88,7 @@
#include <comphelper/documentinfo.hxx>
#include <comphelper/propertysequence.hxx>
#include <comphelper/processfactory.hxx>
+#include <officecfg/Office/Common.hxx>
namespace uno = com::sun::star::uno;
namespace frame = com::sun::star::frame;
@@ -1620,10 +1621,17 @@ IMPL_LINK_NOARG(SvxConfigPage, SelectFunctionHdl, weld::TreeView&, void)
SfxGroupInfo_Impl *pData = reinterpret_cast<SfxGroupInfo_Impl*>(m_xFunctions->get_selected_id().toInt64());
if (pData)
{
+ bool bIsExperimental
+ = vcl::CommandInfoProvider::IsExperimental(pData->sCommand, m_aModuleId);
+
+ OUString aExperimental = "\n" + CuiResId(RID_SVXSTR_COMMANDEXPERIMENTAL);
OUString aLabel = CuiResId(RID_SVXSTR_COMMANDLABEL) + ": " + pData->sLabel + "\n";
OUString aName = CuiResId(RID_SVXSTR_COMMANDNAME) + ": " + pData->sCommand + "\n";
OUString aTip = CuiResId(RID_SVXSTR_COMMANDTIP) + ": " + pData->sTooltip;
- m_xDescriptionField->set_text(aLabel + aName + aTip);
+ if (bIsExperimental)
+ m_xDescriptionField->set_text(aLabel + aName + aTip + aExperimental);
+ else
+ m_xDescriptionField->set_text(aLabel + aName + aTip);
}
}
}