diff options
Diffstat (limited to 'scripting/source')
-rw-r--r-- | scripting/source/basprov/basprov.cxx | 3 | ||||
-rw-r--r-- | scripting/source/inc/util/MiscUtils.hxx | 3 | ||||
-rw-r--r-- | scripting/source/protocolhandler/scripthandler.cxx | 3 | ||||
-rw-r--r-- | scripting/source/provider/MasterScriptProvider.cxx | 3 | ||||
-rw-r--r-- | scripting/source/provider/ProviderCache.cxx | 4 |
5 files changed, 5 insertions, 11 deletions
diff --git a/scripting/source/basprov/basprov.cxx b/scripting/source/basprov/basprov.cxx index ad990dbd4863..0d247130ff9f 100644 --- a/scripting/source/basprov/basprov.cxx +++ b/scripting/source/basprov/basprov.cxx @@ -232,8 +232,7 @@ namespace basprov ); } - OUString sDoc = "vnd.sun.star.tdoc"; - if ( m_sScriptingContext.startsWith( sDoc ) ) + if ( m_sScriptingContext.startsWith( "vnd.sun.star.tdoc" ) ) { xModel = MiscUtils::tDocUrlToModel( m_sScriptingContext ); // TODO: use ScriptingContantsPool for SCRIPTING_DOC_REF diff --git a/scripting/source/inc/util/MiscUtils.hxx b/scripting/source/inc/util/MiscUtils.hxx index f40a51499834..e7b5bd920a58 100644 --- a/scripting/source/inc/util/MiscUtils.hxx +++ b/scripting/source/inc/util/MiscUtils.hxx @@ -108,8 +108,7 @@ static css::uno::Reference< css::frame::XModel > tDocUrlToModel( const OUString& try { ::ucbhelper::Content root( url, nullptr, comphelper::getProcessComponentContext() ); - OUString propName = "DocumentModel"; - result = getUCBProperty( root, propName ); + result = getUCBProperty( root, "DocumentModel" ); } catch ( css::ucb::ContentCreationException& ) { diff --git a/scripting/source/protocolhandler/scripthandler.cxx b/scripting/source/protocolhandler/scripthandler.cxx index ea29661a489a..74aecbeb1e5c 100644 --- a/scripting/source/protocolhandler/scripthandler.cxx +++ b/scripting/source/protocolhandler/scripthandler.cxx @@ -80,8 +80,7 @@ void SAL_CALL ScriptProtocolHandler::initialize( // but usually it's a "real" frame) if ( aArguments.hasElements() && !( aArguments[ 0 ] >>= m_xFrame ) ) { - OUString temp = "ScriptProtocolHandler::initialize: could not extract reference to the frame"; - throw RuntimeException( temp ); + throw RuntimeException( "ScriptProtocolHandler::initialize: could not extract reference to the frame" ); } ENSURE_OR_THROW( m_xContext.is(), "ScriptProtocolHandler::initialize: No Service Manager available" ); diff --git a/scripting/source/provider/MasterScriptProvider.cxx b/scripting/source/provider/MasterScriptProvider.cxx index 2a12c21fb604..d6e64eb92da8 100644 --- a/scripting/source/provider/MasterScriptProvider.cxx +++ b/scripting/source/provider/MasterScriptProvider.cxx @@ -345,8 +345,7 @@ MasterScriptProvider::providerCache() ::osl::MutexGuard aGuard( m_mutex ); if ( !m_pPCache ) { - OUString serviceName1 = "com.sun.star.script.provider.ScriptProviderForBasic"; - Sequence<OUString> blacklist { serviceName1 }; + Sequence<OUString> blacklist { "com.sun.star.script.provider.ScriptProviderForBasic" }; if ( !m_bIsPkgMSP ) { diff --git a/scripting/source/provider/ProviderCache.cxx b/scripting/source/provider/ProviderCache.cxx index e97be35acb6f..4bcbd67f9260 100644 --- a/scripting/source/provider/ProviderCache.cxx +++ b/scripting/source/provider/ProviderCache.cxx @@ -136,10 +136,8 @@ ProviderCache::populateCache() ::osl::Guard< osl::Mutex > aGuard( m_mutex ); try { - OUString const languageProviderName( "com.sun.star.script.provider.LanguageScriptProvider" ); - Reference< container::XContentEnumerationAccess > xEnumAccess( m_xMgr, UNO_QUERY_THROW ); - Reference< container::XEnumeration > xEnum = xEnumAccess->createContentEnumeration ( languageProviderName ); + Reference< container::XEnumeration > xEnum = xEnumAccess->createContentEnumeration ( "com.sun.star.script.provider.LanguageScriptProvider" ); while ( xEnum->hasMoreElements() ) { |