summaryrefslogtreecommitdiff
path: root/stoc/source
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-10-30 08:40:11 +0200
committerNoel Grandin <noelgrandin@gmail.com>2015-10-30 08:59:59 +0000
commit3bc5df7f32501075149e4b41f6e98ea8dd2cfcbd (patch)
tree6e7f5d288cf65935b3ed1f0b88200d32d2f016f0 /stoc/source
parent2e528df76b168a221c6d251d9b076bce5ba051a3 (diff)
UNO: no need to use OUString constructor when calling createInstance
Change-Id: I37da28539b94706574116d0fff5f008aabfb5526 Reviewed-on: https://gerrit.libreoffice.org/19682 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'stoc/source')
-rw-r--r--stoc/source/invocation/invocation.cxx4
-rw-r--r--stoc/source/invocation_adapterfactory/iafactory.cxx2
-rw-r--r--stoc/source/javavm/javavm.cxx11
-rw-r--r--stoc/source/servicemanager/servicemanager.cxx2
4 files changed, 8 insertions, 11 deletions
diff --git a/stoc/source/invocation/invocation.cxx b/stoc/source/invocation/invocation.cxx
index 2f893e6246a4..42657baa9f5c 100644
--- a/stoc/source/invocation/invocation.cxx
+++ b/stoc/source/invocation/invocation.cxx
@@ -1115,9 +1115,7 @@ InvocationService::InvocationService( const Reference<XComponentContext> & xCtx
, xCoreReflection( css::reflection::theCoreReflection::get(mxCtx) )
{
xTypeConverter = Reference<XTypeConverter>(
- mxSMgr->createInstanceWithContext(
- OUString("com.sun.star.script.Converter"),
- xCtx ),
+ mxSMgr->createInstanceWithContext( "com.sun.star.script.Converter", xCtx ),
UNO_QUERY );
xIntrospection = theIntrospection::get(xCtx);
}
diff --git a/stoc/source/invocation_adapterfactory/iafactory.cxx b/stoc/source/invocation_adapterfactory/iafactory.cxx
index 2b953e9a6199..2702b6aa24af 100644
--- a/stoc/source/invocation_adapterfactory/iafactory.cxx
+++ b/stoc/source/invocation_adapterfactory/iafactory.cxx
@@ -700,7 +700,7 @@ FactoryImpl::FactoryImpl( Reference< XComponentContext > const & xContext )
// type converter
Reference< script::XTypeConverter > xConverter(
xContext->getServiceManager()->createInstanceWithContext(
- OUString("com.sun.star.script.Converter"),
+ "com.sun.star.script.Converter",
xContext ),
UNO_QUERY_THROW );
m_pConverter = static_cast<uno_Interface *>(m_aCpp2Uno.mapInterface(
diff --git a/stoc/source/javavm/javavm.cxx b/stoc/source/javavm/javavm.cxx
index 30755663a8c2..c3ec2516c932 100644
--- a/stoc/source/javavm/javavm.cxx
+++ b/stoc/source/javavm/javavm.cxx
@@ -272,7 +272,7 @@ void getINetPropsFromConfig(stoc_javavm::JVM * pjvm,
const css::uno::Reference<css::uno::XComponentContext> &xCtx ) throw (css::uno::Exception)
{
css::uno::Reference<css::uno::XInterface> xConfRegistry = xSMgr->createInstanceWithContext(
- OUString("com.sun.star.configuration.ConfigurationRegistry"),
+ "com.sun.star.configuration.ConfigurationRegistry",
xCtx );
if(!xConfRegistry.is()) throw css::uno::RuntimeException("javavm.cxx: couldn't get ConfigurationRegistry", 0);
@@ -362,8 +362,7 @@ void getDefaultLocaleFromConfig(
const css::uno::Reference<css::uno::XComponentContext> &xCtx ) throw(css::uno::Exception)
{
css::uno::Reference<css::uno::XInterface> xConfRegistry =
- xSMgr->createInstanceWithContext(
- OUString("com.sun.star.configuration.ConfigurationRegistry"), xCtx );
+ xSMgr->createInstanceWithContext( "com.sun.star.configuration.ConfigurationRegistry", xCtx );
if(!xConfRegistry.is())
throw css::uno::RuntimeException(
OUString("javavm.cxx: couldn't get ConfigurationRegistry"), 0);
@@ -417,7 +416,7 @@ void getJavaPropsFromSafetySettings(
{
css::uno::Reference<css::uno::XInterface> xConfRegistry =
xSMgr->createInstanceWithContext(
- OUString("com.sun.star.configuration.ConfigurationRegistry"),
+ "com.sun.star.configuration.ConfigurationRegistry",
xCtx);
if(!xConfRegistry.is())
throw css::uno::RuntimeException(
@@ -1353,7 +1352,7 @@ void JavaVirtualMachine::registerConfigChangesListener()
m_xInetConfiguration
= css::uno::Reference< css::container::XContainer >(
xConfigProvider->createInstanceWithArguments(
- OUString("com.sun.star.configuration.ConfigurationAccess"),
+ "com.sun.star.configuration.ConfigurationAccess",
aArguments),
css::uno::UNO_QUERY);
@@ -1377,7 +1376,7 @@ void JavaVirtualMachine::registerConfigChangesListener()
m_xJavaConfiguration
= css::uno::Reference< css::container::XContainer >(
xConfigProvider->createInstanceWithArguments(
- OUString("com.sun.star.configuration.ConfigurationAccess"),
+ "com.sun.star.configuration.ConfigurationAccess",
aArguments2),
css::uno::UNO_QUERY);
diff --git a/stoc/source/servicemanager/servicemanager.cxx b/stoc/source/servicemanager/servicemanager.cxx
index 92589f967284..4d10bd44e99d 100644
--- a/stoc/source/servicemanager/servicemanager.cxx
+++ b/stoc/source/servicemanager/servicemanager.cxx
@@ -1410,7 +1410,7 @@ Reference<XRegistryKey > ORegistryServiceManager::getRootKey()
m_xRegistry.set(
createInstanceWithContext(
- OUString("com.sun.star.registry.DefaultRegistry"),
+ "com.sun.star.registry.DefaultRegistry",
m_xContext ),
UNO_QUERY );
}