summaryrefslogtreecommitdiff
path: root/scripting/source/dlgprov
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2016-11-01 13:18:59 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2016-11-01 12:34:51 +0000
commit39414827352e58e8be76abaa9a5a1ac9518d927f (patch)
tree7b856026bae224c678cab020ce00f97574d2bbba /scripting/source/dlgprov
parentd5c4823555e6f5c4e3bd9258c819bb2a763227c4 (diff)
loplugin:oncevar in sal..scripting
Change-Id: Id9ab12f3a61eb83a2288b2fd4d99ab77f5833e1b Reviewed-on: https://gerrit.libreoffice.org/30461 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'scripting/source/dlgprov')
-rw-r--r--scripting/source/dlgprov/dlgevtatt.cxx4
-rw-r--r--scripting/source/dlgprov/dlgprov.cxx8
2 files changed, 3 insertions, 9 deletions
diff --git a/scripting/source/dlgprov/dlgevtatt.cxx b/scripting/source/dlgprov/dlgevtatt.cxx
index 4e94a6f8f53a..633ec641ad88 100644
--- a/scripting/source/dlgprov/dlgevtatt.cxx
+++ b/scripting/source/dlgprov/dlgevtatt.cxx
@@ -536,9 +536,7 @@ namespace dlgprov
void DialogUnoScriptListenerImpl::firing_impl( const ScriptEvent& aScriptEvent, Any* pRet )
{
- static const char sUnoURLScheme[] = "vnd.sun.star.UNO:";
-
- OUString aMethodName = aScriptEvent.ScriptCode.copy( strlen(sUnoURLScheme) );
+ OUString aMethodName = aScriptEvent.ScriptCode.copy( strlen("vnd.sun.star.UNO:") );
const Any* pArguments = aScriptEvent.Arguments.getConstArray();
Any aEventObject = pArguments[0];
diff --git a/scripting/source/dlgprov/dlgprov.cxx b/scripting/source/dlgprov/dlgprov.cxx
index 4adfd13e6c2f..c47a84959277 100644
--- a/scripting/source/dlgprov/dlgprov.cxx
+++ b/scripting/source/dlgprov/dlgprov.cxx
@@ -86,9 +86,6 @@ namespace comp_DialogModelProvider
namespace dlgprov
{
-
-static const char aResourceResolverPropName[] = "ResourceResolver";
-
Reference< resource::XStringResourceManager > lcl_getStringResourceManager(const Reference< XComponentContext >& i_xContext,const OUString& i_sURL)
{
INetURLObject aInetObj( i_sURL );
@@ -153,7 +150,7 @@ static const char aResourceResolverPropName[] = "ResourceResolver";
Reference< beans::XPropertySet > xDlgPSet( xDialogModel, UNO_QUERY );
Any aStringResourceManagerAny;
aStringResourceManagerAny <<= xStringResourceManager;
- xDlgPSet->setPropertyValue( aResourceResolverPropName, aStringResourceManagerAny );
+ xDlgPSet->setPropertyValue( "ResourceResolver", aStringResourceManagerAny );
}
return xDialogModel;
@@ -614,7 +611,6 @@ static const char aResourceResolverPropName[] = "ResourceResolver";
static const char aDecorationPropName[] = "Decoration";
- static const char aTitlePropName[] = "Title";
Reference < XControl > DialogProviderImpl::createDialogImpl(
const OUString& URL, const Reference< XInterface >& xHandler,
@@ -664,7 +660,7 @@ static const char aResourceResolverPropName[] = "ResourceResolver";
if( !bDecoration )
{
xDlgModPropSet->setPropertyValue( aDecorationPropName, makeAny( true ) );
- xDlgModPropSet->setPropertyValue( aTitlePropName, makeAny( OUString() ) );
+ xDlgModPropSet->setPropertyValue( "Title", makeAny( OUString() ) );
}
}
catch( UnknownPropertyException& )