summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2016-04-15 13:38:17 +0200
committerSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2016-04-15 13:01:15 +0000
commit7ae232623a423b078dd54d06e5fe52e89994b391 (patch)
treeb5f9ded5554be23b46f15c751a52ca07b6a67bb2 /vcl
parent9a081c5cb56c834e7b63ee1ad5b88f11119891ff (diff)
tdf#95845 Use CommandInfoProvider in forms
Change-Id: I697f8c442cc4db7b38601c32fb71e0201f145354 Reviewed-on: https://gerrit.libreoffice.org/24106 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/helper/commandinfoprovider.cxx7
1 files changed, 3 insertions, 4 deletions
diff --git a/vcl/source/helper/commandinfoprovider.cxx b/vcl/source/helper/commandinfoprovider.cxx
index 77d5ba6903de..7a03c80afa7b 100644
--- a/vcl/source/helper/commandinfoprovider.cxx
+++ b/vcl/source/helper/commandinfoprovider.cxx
@@ -480,14 +480,13 @@ OUString CommandInfoProvider::GetCommandProperty(const OUString& rsProperty, con
return OUString();
}
-OUString CommandInfoProvider::GetCommandPropertyFromModule( const sal_Char* pCommandURL, const OUString& rModuleName )
+OUString CommandInfoProvider::GetCommandPropertyFromModule( const OUString& rCommandName, const OUString& rModuleName )
{
OUString sLabel;
- if ( !pCommandURL || !*pCommandURL )
+ if ( rCommandName.isEmpty() )
return sLabel;
Sequence<beans::PropertyValue> aProperties;
- OUString sCommandURL = OUString::createFromAscii( pCommandURL );
try
{
if( rModuleName.getLength() > 0)
@@ -495,7 +494,7 @@ OUString CommandInfoProvider::GetCommandPropertyFromModule( const sal_Char* pCom
Reference<container::XNameAccess> xNameAccess = frame::theUICommandDescription::get(mxContext);
Reference<container::XNameAccess> xUICommandLabels;
if (xNameAccess->getByName( rModuleName ) >>= xUICommandLabels )
- xUICommandLabels->getByName(sCommandURL) >>= aProperties;
+ xUICommandLabels->getByName(rCommandName) >>= aProperties;
for (sal_Int32 nIndex=0; nIndex<aProperties.getLength(); ++nIndex)
{