summaryrefslogtreecommitdiff
path: root/desktop
diff options
context:
space:
mode:
authorThomas Arnhold <thomas@arnhold.org>2013-06-29 21:24:12 +0200
committerThomas Arnhold <thomas@arnhold.org>2013-06-29 21:52:54 +0000
commitba0a57702cdef7a0389c06841711d7e3079d471c (patch)
tree223c0dd50de4b71cf7df9d0073f7cacca1f18c8d /desktop
parent8a7ede404ca4980f169c4ce634805ea5c1b6b56e (diff)
remove OUString wrap for string literals
For some functions and all kinds of Exceptions. CannotConvertException CloseVetoException DisposedException EmptyUndoStackException ErrorCodeIOException Exception GridInvalidDataException GridInvalidModelException IOException IllegalAccessException IllegalArgumentException IllegalTypeException IndexOutOfBoundsException NoMasterException NoSuchElementException NoSupportException PropertyVetoException RuntimeException SAXException ScannerException StorageWrappedTargetException UnsupportedFlavorException VetoException WrappedTargetException ZipIOException throwGenericSQLException throwIllegallArgumentException createInstance createInstanceWithContext forName getByName getPackageManager getPropertyValue getUnpackedValueOrDefault getValueByName hasPropertyByName openKey setName setPropertyValue supportsService bash command: for i in `cat list`; do git grep "$i\s*(\s*OUString(\s*\"" -- '*.[hc]xx' | cut -d ':' -f1 | sort -u | xargs sed -i -e "s/\(\<$i\s*(\)\s*OUString(\s*\(\"[^\")\\]*\"\)\s*)\s*/\1\2/g" -e "s/\($i.*\)\"+ /\1\" + /g"; done Change-Id: Iaf8e641b0abf28c082906014f87a183517630535 Reviewed-on: https://gerrit.libreoffice.org/4624 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Thomas Arnhold <thomas@arnhold.org> Tested-by: Thomas Arnhold <thomas@arnhold.org>
Diffstat (limited to 'desktop')
-rw-r--r--desktop/source/app/app.cxx20
-rw-r--r--desktop/source/app/check_ext_deps.cxx6
-rw-r--r--desktop/source/deployment/gui/dp_gui_theextmgr.cxx6
3 files changed, 16 insertions, 16 deletions
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index f2b7a0e23a55..a6888b5180df 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -2028,8 +2028,8 @@ void Desktop::EnableOleAutomation()
SAL_INFO( "desktop.app", "desktop (jl97489) ::Desktop::EnableOleAutomation" );
#ifdef WNT
Reference< XMultiServiceFactory > xSMgr= comphelper::getProcessServiceFactory();
- xSMgr->createInstance(OUString("com.sun.star.bridge.OleApplicationRegistration"));
- xSMgr->createInstance(OUString("com.sun.star.comp.ole.EmbedServer"));
+ xSMgr->createInstance("com.sun.star.bridge.OleApplicationRegistration");
+ xSMgr->createInstance("com.sun.star.comp.ole.EmbedServer");
#endif
}
@@ -2110,8 +2110,8 @@ void Desktop::PreloadConfigurationData()
a >>= xCmdAccess;
if ( xCmdAccess.is() )
{
- xCmdAccess->getByName( OUString( ".uno:BasicShapes" ));
- xCmdAccess->getByName( OUString( ".uno:EditGlossary" ));
+ xCmdAccess->getByName(".uno:BasicShapes");
+ xCmdAccess->getByName(".uno:EditGlossary");
}
}
catch ( const ::com::sun::star::uno::Exception& )
@@ -2123,7 +2123,7 @@ void Desktop::PreloadConfigurationData()
a = xNameAccess->getByName( aCalcDoc );
a >>= xCmdAccess;
if ( xCmdAccess.is() )
- xCmdAccess->getByName( OUString( ".uno:InsertObjectStarMath" ));
+ xCmdAccess->getByName(".uno:InsertObjectStarMath");
}
catch ( const ::com::sun::star::uno::Exception& )
{
@@ -2135,7 +2135,7 @@ void Desktop::PreloadConfigurationData()
a = xNameAccess->getByName( aDrawDoc );
a >>= xCmdAccess;
if ( xCmdAccess.is() )
- xCmdAccess->getByName( OUString( ".uno:Polygon" ));
+ xCmdAccess->getByName(".uno:Polygon");
}
catch ( const ::com::sun::star::uno::Exception& )
{
@@ -2149,7 +2149,7 @@ void Desktop::PreloadConfigurationData()
a = xNameAccess->getByName( aWriterDoc );
a >>= xWindowAccess;
if ( xWindowAccess.is() )
- xWindowAccess->getByName( OUString( "private:resource/toolbar/standardbar" ));
+ xWindowAccess->getByName("private:resource/toolbar/standardbar");
}
catch ( const ::com::sun::star::uno::Exception& )
{
@@ -2159,7 +2159,7 @@ void Desktop::PreloadConfigurationData()
a = xNameAccess->getByName( aCalcDoc );
a >>= xWindowAccess;
if ( xWindowAccess.is() )
- xWindowAccess->getByName( OUString( "private:resource/toolbar/standardbar" ));
+ xWindowAccess->getByName("private:resource/toolbar/standardbar");
}
catch ( const ::com::sun::star::uno::Exception& )
{
@@ -2169,7 +2169,7 @@ void Desktop::PreloadConfigurationData()
a = xNameAccess->getByName( aDrawDoc );
a >>= xWindowAccess;
if ( xWindowAccess.is() )
- xWindowAccess->getByName( OUString( "private:resource/toolbar/standardbar" ));
+ xWindowAccess->getByName("private:resource/toolbar/standardbar");
}
catch ( const ::com::sun::star::uno::Exception& )
{
@@ -2179,7 +2179,7 @@ void Desktop::PreloadConfigurationData()
a = xNameAccess->getByName( aImpressDoc );
a >>= xWindowAccess;
if ( xWindowAccess.is() )
- xWindowAccess->getByName( OUString( "private:resource/toolbar/standardbar" ));
+ xWindowAccess->getByName("private:resource/toolbar/standardbar");
}
catch ( const ::com::sun::star::uno::Exception& )
{
diff --git a/desktop/source/app/check_ext_deps.cxx b/desktop/source/app/check_ext_deps.cxx
index 53ee92ea8561..fbaf3e1eae63 100644
--- a/desktop/source/app/check_ext_deps.cxx
+++ b/desktop/source/app/check_ext_deps.cxx
@@ -332,7 +332,7 @@ static void impl_setNeedsCompatCheck()
Any value = makeAny( OUString("never") );
- pset->setPropertyValue( OUString("LastCompatibilityCheckID"), value );
+ pset->setPropertyValue("LastCompatibilityCheckID", value );
Reference< util::XChangesBatch >( pset, UNO_QUERY_THROW )->commitChanges();
}
catch (const Exception&) {}
@@ -361,14 +361,14 @@ static bool impl_needsCompatCheck()
Reference< beans::XPropertySet > pset = Reference< beans::XPropertySet >(
theConfigProvider->createInstanceWithArguments( OUString(aAccessSrvc), theArgs ), UNO_QUERY_THROW );
- Any result = pset->getPropertyValue( OUString("LastCompatibilityCheckID") );
+ Any result = pset->getPropertyValue("LastCompatibilityCheckID");
result >>= aLastCheckBuildID;
if ( aLastCheckBuildID != aCurrentBuildID )
{
bNeedsCheck = true;
result <<= aCurrentBuildID;
- pset->setPropertyValue( OUString("LastCompatibilityCheckID"), result );
+ pset->setPropertyValue("LastCompatibilityCheckID", result );
Reference< util::XChangesBatch >( pset, UNO_QUERY_THROW )->commitChanges();
}
#ifdef DEBUG
diff --git a/desktop/source/deployment/gui/dp_gui_theextmgr.cxx b/desktop/source/deployment/gui/dp_gui_theextmgr.cxx
index af1576460532..21964b4a9096 100644
--- a/desktop/source/deployment/gui/dp_gui_theextmgr.cxx
+++ b/desktop/source/deployment/gui/dp_gui_theextmgr.cxx
@@ -80,7 +80,7 @@ TheExtensionManager::TheExtensionManager( Window *pParent,
uno::Sequence< uno::Any >( args, 1 )), uno::UNO_QUERY_THROW);
try
{ //throws css::container::NoSuchElementException, css::lang::WrappedTargetException
- uno::Any value = xNameAccessRepositories->getByName( OUString( "WebsiteLink" ) );
+ uno::Any value = xNameAccessRepositories->getByName("WebsiteLink");
m_sGetExtensionsURL = value.get< OUString > ();
}
catch ( const uno::Exception& )
@@ -380,7 +380,7 @@ bool TheExtensionManager::supportsOptions( const uno::Reference< deployment::XPa
uno::Reference< XInterface> xIntNode = anyNode.get< uno::Reference< XInterface > >();
uno::Reference< container::XNameAccess > xNode( xIntNode, uno::UNO_QUERY_THROW );
- uno::Any anyLeaves = xNode->getByName( OUString("Leaves") );
+ uno::Any anyLeaves = xNode->getByName("Leaves");
uno::Reference< XInterface > xIntLeaves = anyLeaves.get< uno::Reference< XInterface > >();
uno::Reference< container::XNameAccess > xLeaves( xIntLeaves, uno::UNO_QUERY_THROW );
@@ -393,7 +393,7 @@ bool TheExtensionManager::supportsOptions( const uno::Reference< deployment::XPa
uno::Reference< beans::XPropertySet > xLeaf( xIntLeaf, uno::UNO_QUERY_THROW );
//investigate the Id property if it matches the extension identifier which
//has been passed in.
- uno::Any anyValue = xLeaf->getPropertyValue( OUString("Id") );
+ uno::Any anyValue = xLeaf->getPropertyValue("Id");
OUString sId = anyValue.get< OUString >();
if ( sId == aId.Value )