[Libreoffice-commits] core.git: 4 commits - toolkit/source ucbhelper/source ucb/source ucb/workben unotools/source
Noel Grandin
noel at peralex.com
Thu Nov 7 13:27:35 CET 2013
toolkit/source/awt/vclxaccessiblecomponent.cxx | 2 -
toolkit/source/awt/vclxwindow1.cxx | 4 +--
toolkit/source/controls/roadmapentry.cxx | 2 -
toolkit/source/controls/unocontrol.cxx | 2 -
toolkit/source/controls/unocontrols.cxx | 10 +++----
ucb/source/core/ucb.cxx | 3 --
ucb/source/core/ucbcmds.cxx | 31 ++++++++++--------------
ucb/source/sorter/sortresult.cxx | 8 +++---
ucb/source/ucp/cmis/cmis_datasupplier.cxx | 2 -
ucb/source/ucp/file/bc.cxx | 2 -
ucb/source/ucp/file/filglob.cxx | 24 +++++++++---------
ucb/source/ucp/file/filinsreq.cxx | 6 ++--
ucb/source/ucp/file/filrset.cxx | 8 +++---
ucb/source/ucp/file/shell.cxx | 26 ++++++++++----------
ucb/source/ucp/ftp/ftpcontent.cxx | 8 +++---
ucb/source/ucp/ftp/ftpresultsetbase.cxx | 4 +--
ucb/source/ucp/ftp/ftpurl.cxx | 2 -
ucb/source/ucp/gio/gio_content.cxx | 4 +--
ucb/source/ucp/gio/gio_datasupplier.cxx | 2 -
ucb/source/ucp/gvfs/gvfs_content.cxx | 6 ++--
ucb/source/ucp/hierarchy/hierarchycontent.cxx | 26 ++++++++------------
ucb/source/ucp/hierarchy/hierarchyuri.cxx | 18 +++++++-------
ucb/source/ucp/package/pkgcontent.cxx | 10 +++----
ucb/source/ucp/tdoc/tdoc_content.cxx | 24 +++++++-----------
ucb/source/ucp/tdoc/tdoc_uri.cxx | 2 -
ucb/source/ucp/webdav-neon/DAVProperties.cxx | 8 +-----
ucb/source/ucp/webdav-neon/webdavcontent.cxx | 29 ++++++++++------------
ucb/workben/ucb/ucbdemo.cxx | 29 ++++++++++------------
ucbhelper/source/client/content.cxx | 32 ++++++++++++-------------
ucbhelper/source/client/proxydecider.cxx | 2 -
unotools/source/config/eventcfg.cxx | 6 ++--
unotools/source/config/lingucfg.cxx | 2 -
unotools/source/i18n/localedatawrapper.cxx | 10 +++----
unotools/source/ucbhelper/ucbhelper.cxx | 4 +--
unotools/source/ucbhelper/ucblockbytes.cxx | 4 +--
35 files changed, 169 insertions(+), 193 deletions(-)
New commits:
commit 5d7bf132bda6e870e5333675c1897960d2c0134c
Author: Noel Grandin <noel at peralex.com>
Date: Thu Oct 31 15:43:06 2013 +0200
remove unnecessary use of OUString constructor in TOOLKIT module
Change-Id: I0cc8c507ede20d5db1942b75e0c4b660dcd66c97
diff --git a/toolkit/source/awt/vclxaccessiblecomponent.cxx b/toolkit/source/awt/vclxaccessiblecomponent.cxx
index 341d829..e1be4c1 100644
--- a/toolkit/source/awt/vclxaccessiblecomponent.cxx
+++ b/toolkit/source/awt/vclxaccessiblecomponent.cxx
@@ -103,7 +103,7 @@ sal_Bool VCLXAccessibleComponent::supportsService( const OUString& rServiceName
uno::Sequence< OUString > VCLXAccessibleComponent::getSupportedServiceNames() throw (uno::RuntimeException)
{
uno::Sequence< OUString > aNames(1);
- aNames[0] = OUString("com.sun.star.awt.AccessibleWindow");
+ aNames[0] = "com.sun.star.awt.AccessibleWindow";
return aNames;
}
diff --git a/toolkit/source/awt/vclxwindow1.cxx b/toolkit/source/awt/vclxwindow1.cxx
index 12022d1..9476b37 100644
--- a/toolkit/source/awt/vclxwindow1.cxx
+++ b/toolkit/source/awt/vclxwindow1.cxx
@@ -43,7 +43,7 @@ void VCLXWindow::SetSystemParent_Impl( const com::sun::star::uno::Any& rHandle )
if ( pWindow->GetType() != WINDOW_WORKWINDOW )
{
com::sun::star::uno::Exception aException;
- aException.Message = OUString("not a work window");
+ aException.Message = "not a work window";
throw aException;
}
@@ -73,7 +73,7 @@ void VCLXWindow::SetSystemParent_Impl( const com::sun::star::uno::Any& rHandle )
if( bThrow )
{
com::sun::star::uno::Exception aException;
- aException.Message = OUString("incorrect window handle type");
+ aException.Message = "incorrect window handle type";
throw aException;
}
// create system parent data
diff --git a/toolkit/source/controls/roadmapentry.cxx b/toolkit/source/controls/roadmapentry.cxx
index 4bf6a48..e636552 100644
--- a/toolkit/source/controls/roadmapentry.cxx
+++ b/toolkit/source/controls/roadmapentry.cxx
@@ -93,7 +93,7 @@ sal_Bool SAL_CALL ORoadmapEntry::supportsService( const OUString& ServiceName )
{
::com::sun::star::uno::Sequence< OUString > aRet(1);
OUString* pArray = aRet.getArray();
- pArray[0] = OUString("com.sun.star.awt.RoadmapItem");
+ pArray[0] = "com.sun.star.awt.RoadmapItem";
return aRet;
}
//--------------------------------------------------------------------------
diff --git a/toolkit/source/controls/unocontrol.cxx b/toolkit/source/controls/unocontrol.cxx
index 3830c242..f597c64 100644
--- a/toolkit/source/controls/unocontrol.cxx
+++ b/toolkit/source/controls/unocontrol.cxx
@@ -1090,7 +1090,7 @@ void UnoControl::createPeer( const Reference< XToolkit >& rxToolkit, const Refer
if ( !mxModel.is() )
{
RuntimeException aException;
- aException.Message = OUString("createPeer: no model!");
+ aException.Message = "createPeer: no model!";
aException.Context = (XAggregation*)(::cppu::OWeakAggObject*)this;
throw( aException );
}
diff --git a/toolkit/source/controls/unocontrols.cxx b/toolkit/source/controls/unocontrols.cxx
index e2503cf..3a4c59a 100644
--- a/toolkit/source/controls/unocontrols.cxx
+++ b/toolkit/source/controls/unocontrols.cxx
@@ -107,7 +107,7 @@ ImageHelper::getGraphicFromURL_nothrow( const OUString& _rURL )
uno::Reference< uno::XComponentContext > xContext( ::comphelper::getProcessComponentContext() );
uno::Reference< graphic::XGraphicProvider > xProvider( graphic::GraphicProvider::create(xContext) );
uno::Sequence< beans::PropertyValue > aMediaProperties(1);
- aMediaProperties[0].Name = OUString( "URL" );
+ aMediaProperties[0].Name = "URL";
aMediaProperties[0].Value <<= _rURL;
xGraphic = xProvider->queryGraphic( aMediaProperties );
}
@@ -221,7 +221,7 @@ OUString UnoEditControl::GetComponentServiceName()
uno::Any aVal = ImplGetPropertyValue( GetPropertyName( BASEPROPERTY_MULTILINE ) );
sal_Bool b = sal_Bool();
if ( ( aVal >>= b ) && b )
- sName= OUString("MultiLineEdit");
+ sName = "MultiLineEdit";
return sName;
}
@@ -711,11 +711,11 @@ OUString UnoButtonControl::GetComponentServiceName()
// Use PushButtonType later when available...
switch ( n )
{
- case 1 /*PushButtonType::OK*/: aName= OUString("okbutton");
+ case 1 /*PushButtonType::OK*/: aName = "okbutton";
break;
- case 2 /*PushButtonType::CANCEL*/: aName= OUString("cancelbutton");
+ case 2 /*PushButtonType::CANCEL*/: aName = "cancelbutton";
break;
- case 3 /*PushButtonType::HELP*/: aName= OUString("helpbutton");
+ case 3 /*PushButtonType::HELP*/: aName = "helpbutton";
break;
default:
{
commit 24857c46daf06553e8618de46a0f3ece27c32675
Author: Noel Grandin <noel at peralex.com>
Date: Thu Oct 31 15:40:40 2013 +0200
remove unnecessary use of OUString constructor in UCB module
Change-Id: Ic75e5aad03d66590e78275304c766c1c00179387
diff --git a/ucb/source/core/ucb.cxx b/ucb/source/core/ucb.cxx
index 3d0e7d7..69555ab 100644
--- a/ucb/source/core/ucb.cxx
+++ b/ucb/source/core/ucb.cxx
@@ -883,8 +883,7 @@ bool UniversalContentBroker::getContentProviderData(
uno::Sequence< uno::Any > aArguments( 1 );
beans::PropertyValue aProperty;
- aProperty.Name
- = OUString( "nodepath" );
+ aProperty.Name = "nodepath";
aProperty.Value <<= aFullPath.makeStringAndClear();
aArguments[ 0 ] <<= aProperty;
diff --git a/ucb/source/core/ucbcmds.cxx b/ucb/source/core/ucbcmds.cxx
index d969330..75f03f7 100644
--- a/ucb/source/core/ucbcmds.cxx
+++ b/ucb/source/core/ucbcmds.cxx
@@ -484,8 +484,7 @@ bool setTitle(
try
{
uno::Sequence< beans::PropertyValue > aPropValues( 1 );
- aPropValues[ 0 ].Name
- = OUString( "Title" );
+ aPropValues[ 0 ].Name = "Title";
aPropValues[ 0 ].Handle = -1;
aPropValues[ 0 ].Value = uno::makeAny( rNewTitle );
@@ -560,10 +559,8 @@ uno::Reference< ucb::XContent > createNew(
}
uno::Sequence< beans::Property > aPropsToObtain( 1 );
- aPropsToObtain[ 0 ].Name
- = OUString("CreatableContentsInfo");
- aPropsToObtain[ 0 ].Handle
- = -1;
+ aPropsToObtain[ 0 ].Name = "CreatableContentsInfo";
+ aPropsToObtain[ 0 ].Handle = -1;
ucb::Command aGetPropsCommand(
OUString("getPropertyValues"),
@@ -879,8 +876,7 @@ void transferProperties(
// Title needed, but not set yet?
if ( !bHasTitle && !rContext.aArg.NewTitle.isEmpty() )
{
- aPropValues[ nWritePos ].Name
- = OUString("Title");
+ aPropValues[ nWritePos ].Name = "Title";
aPropValues[ nWritePos ].Handle = -1;
aPropValues[ nWritePos ].Value <<= rContext.aArg.NewTitle;
@@ -891,8 +887,7 @@ void transferProperties(
if ( !bHasTargetURL && ( rContext.aArg.Operation
== ucb::TransferCommandOperation_LINK ) )
{
- aPropValues[ nWritePos ].Name
- = OUString("TargetURL");
+ aPropValues[ nWritePos ].Name = "TargetURL";
aPropValues[ nWritePos ].Handle = -1;
aPropValues[ nWritePos ].Value <<= rContext.aArg.SourceURL;
@@ -1006,11 +1001,11 @@ uno::Reference< sdbc::XResultSet > getResultSet(
uno::Sequence< beans::Property > aProps( 3 );
- aProps[ 0 ].Name = OUString("IsFolder");
+ aProps[ 0 ].Name = "IsFolder";
aProps[ 0 ].Handle = -1; /* unknown */
- aProps[ 1 ].Name = OUString("IsDocument");
+ aProps[ 1 ].Name = "IsDocument";
aProps[ 1 ].Handle = -1; /* unknown */
- aProps[ 2 ].Name = OUString("TargetURL");
+ aProps[ 2 ].Name = "TargetURL";
aProps[ 2 ].Handle = -1; /* unknown */
ucb::OpenCommandArgument2 aArg;
@@ -1057,7 +1052,7 @@ void handleNameClashRename(
// Obtain old title.
uno::Sequence< beans::Property > aProps( 1 );
- aProps[ 0 ].Name = OUString("Title");
+ aProps[ 0 ].Name = "Title";
aProps[ 0 ].Handle = -1;
ucb::Command aGetPropsCommand(
@@ -1958,13 +1953,13 @@ void UniversalContentBroker::globalTransfer(
uno::Sequence< beans::Property > aProps( 4 );
- aProps[ 0 ].Name = OUString("IsFolder");
+ aProps[ 0 ].Name = "IsFolder";
aProps[ 0 ].Handle = -1; /* unknown */
- aProps[ 1 ].Name = OUString("IsDocument");
+ aProps[ 1 ].Name = "IsDocument";
aProps[ 1 ].Handle = -1; /* unknown */
- aProps[ 2 ].Name = OUString("TargetURL");
+ aProps[ 2 ].Name = "TargetURL";
aProps[ 2 ].Handle = -1; /* unknown */
- aProps[ 3 ].Name = OUString("BaseURI");
+ aProps[ 3 ].Name = "BaseURI";
aProps[ 3 ].Handle = -1; /* unknown */
ucb::Command aGetPropsCommand(
diff --git a/ucb/source/sorter/sortresult.cxx b/ucb/source/sorter/sortresult.cxx
index accf348..cb07ef2 100644
--- a/ucb/source/sorter/sortresult.cxx
+++ b/ucb/source/sorter/sortresult.cxx
@@ -1484,7 +1484,7 @@ void SortedResultSet::CheckProperties( sal_IntPtr nOldCount, sal_Bool bWasFinal
sal_Bool bIsFinal = sal_False;
PropertyChangeEvent aEvt;
- aEvt.PropertyName = OUString("RowCount");
+ aEvt.PropertyName = "RowCount";
aEvt.Further = sal_False;
aEvt.PropertyHandle = -1;
aEvt.OldValue <<= nOldCount;
@@ -1492,7 +1492,7 @@ void SortedResultSet::CheckProperties( sal_IntPtr nOldCount, sal_Bool bWasFinal
PropertyChanged( aEvt );
- OUString aName = OUString("IsRowCountFinal");
+ OUString aName = "IsRowCountFinal";
Any aRet = getPropertyValue( aName );
if ( (aRet >>= bIsFinal) && bIsFinal != bWasFinal )
{
@@ -1998,12 +1998,12 @@ void SimpleList::Replace( void* pData, sal_uInt32 nPos )
SRSPropertySetInfo::SRSPropertySetInfo()
{
- maProps[0].Name = OUString("RowCount");
+ maProps[0].Name = "RowCount";
maProps[0].Handle = -1;
maProps[0].Type = ::getCppuType( (const OUString*) NULL );
maProps[0].Attributes = -1;
- maProps[1].Name = OUString("IsRowCountFinal");
+ maProps[1].Name = "IsRowCountFinal";
maProps[1].Handle = -1;
maProps[1].Type = ::getBooleanCppuType();
maProps[1].Attributes = -1;
diff --git a/ucb/source/ucp/cmis/cmis_datasupplier.cxx b/ucb/source/ucp/cmis/cmis_datasupplier.cxx
index f128c94..4899a71 100644
--- a/ucb/source/ucp/cmis/cmis_datasupplier.cxx
+++ b/ucb/source/ucp/cmis/cmis_datasupplier.cxx
@@ -134,7 +134,7 @@ namespace cmis
xContent, uno::UNO_QUERY_THROW );
sal_Int32 nCmdId( xCmdProc->createCommandIdentifier() );
ucb::Command aCmd;
- aCmd.Name = OUString("getPropertyValues");
+ aCmd.Name = "getPropertyValues";
aCmd.Handle = -1;
aCmd.Argument <<= getResultSet()->getProperties();
uno::Any aResult( xCmdProc->execute(
diff --git a/ucb/source/ucp/file/bc.cxx b/ucb/source/ucp/file/bc.cxx
index e179bfd..0578243 100644
--- a/ucb/source/ucp/file/bc.cxx
+++ b/ucb/source/ucp/file/bc.cxx
@@ -278,7 +278,7 @@ BaseContent::getSupportedServiceNames()
throw( RuntimeException )
{
Sequence< OUString > ret( 1 );
- ret[0] = OUString("com.sun.star.ucb.FileContent");
+ ret[0] = "com.sun.star.ucb.FileContent";
return ret;
}
diff --git a/ucb/source/ucp/file/filglob.cxx b/ucb/source/ucp/file/filglob.cxx
index e830a5e..5ff18a2 100644
--- a/ucb/source/ucp/file/filglob.cxx
+++ b/ucb/source/ucp/file/filglob.cxx
@@ -85,13 +85,13 @@ namespace {
switch (aStatus.getFileType())
{
case osl::FileStatus::Directory:
- aResourceType = OUString( "folder");
+ aResourceType = "folder";
bResourceType = true;
break;
case osl::FileStatus::Volume:
{
- aResourceType = OUString( "volume");
+ aResourceType = "volume";
bResourceType = true;
osl::VolumeInfo aVolumeInfo(
osl_VolumeInfo_Mask_Attributes );
@@ -555,7 +555,7 @@ namespace fileaccess {
excep.Name = getTitle(aUncPath);
excep.Classification = InteractionClassification_ERROR;
excep.Context = xComProc;
- excep.Message = OUString( "file exists and overwrite forbidden");
+ excep.Message = "file exists and overwrite forbidden";
aAny <<= excep;
cancelCommandExecution( aAny,xEnv );
}
@@ -564,7 +564,7 @@ namespace fileaccess {
InteractiveAugmentedIOException excep;
excep.Code = IOErrorCode_INVALID_CHARACTER;
PropertyValue prop;
- prop.Name = OUString("ResourceName");
+ prop.Name = "ResourceName";
prop.Handle = -1;
OUString m_aClashingName(
rtl::Uri::decode(
@@ -577,7 +577,7 @@ namespace fileaccess {
excep.Arguments = seq;
excep.Classification = InteractionClassification_ERROR;
excep.Context = xComProc;
- excep.Message = OUString( "the name contained invalid characters");
+ excep.Message = "the name contained invalid characters";
if(isHandled)
throw excep;
else {
@@ -598,7 +598,7 @@ namespace fileaccess {
excep.Name = getTitle(aUncPath);
excep.Classification = InteractionClassification_ERROR;
excep.Context = xComProc;
- excep.Message = OUString( "folder exists and overwrite forbidden");
+ excep.Message = "folder exists and overwrite forbidden";
if(isHandled)
throw excep;
else {
@@ -756,18 +756,18 @@ namespace fileaccess {
errorCode == TASKHANDLING_TRANSFER_BY_MOVE_SOURCESTAT )
{
ioErrorCode = IOErrorCode_NOT_EXISTING;
- aMsg = OUString( "source file/folder does not exist");
+ aMsg = "source file/folder does not exist";
break;
}
else
{
ioErrorCode = IOErrorCode_GENERAL;
- aMsg = OUString( "a general error during transfer command");
+ aMsg = "a general error during transfer command";
break;
}
default:
ioErrorCode = IOErrorCode_GENERAL;
- aMsg = OUString( "a general error during transfer command");
+ aMsg = "a general error during transfer command";
break;
}
cancelCommandExecution(
@@ -831,7 +831,7 @@ namespace fileaccess {
break;
case FileBase::E_NOENT: // No such file or directory
ioErrorCode = IOErrorCode_NOT_EXISTING;
- aMsg = OUString( "file/folder does not exist");
+ aMsg = "file/folder does not exist";
break;
case FileBase::E_ROFS: // Read-only file system<p>
ioErrorCode = IOErrorCode_NOT_EXISTING;
@@ -854,7 +854,7 @@ namespace fileaccess {
excep.Name = getTitle(aUncPath);
excep.Classification = InteractionClassification_ERROR;
excep.Context = xComProc;
- excep.Message = OUString( "name clash during copy or move");
+ excep.Message = "name clash during copy or move";
aAny <<= excep;
cancelCommandExecution(aAny,xEnv);
@@ -865,7 +865,7 @@ namespace fileaccess {
UnsupportedNameClashException excep;
excep.NameClash = minorCode;
excep.Context = xComProc;
- excep.Message = OUString( "name clash value not supported during copy or move");
+ excep.Message = "name clash value not supported during copy or move";
aAny <<= excep;
cancelCommandExecution(aAny,xEnv);
diff --git a/ucb/source/ucp/file/filinsreq.cxx b/ucb/source/ucp/file/filinsreq.cxx
index c9629d4..49a7dac 100644
--- a/ucb/source/ucp/file/filinsreq.cxx
+++ b/ucb/source/ucp/file/filinsreq.cxx
@@ -186,7 +186,7 @@ XInteractionRequestImpl::getRequest()
excep.Name = m_aClashingName;
excep.Classification = InteractionClassification_ERROR;
excep.Context = m_xOrigin;
- excep.Message = OUString( "folder exists and overwritte forbidden");
+ excep.Message = "folder exists and overwritte forbidden";
aAny <<= excep;
}
else if(m_nErrorCode == TASKHANDLING_INVALID_NAME_MKDIR)
@@ -194,7 +194,7 @@ XInteractionRequestImpl::getRequest()
InteractiveAugmentedIOException excep;
excep.Code = IOErrorCode_INVALID_CHARACTER;
PropertyValue prop;
- prop.Name = OUString("ResourceName");
+ prop.Name = "ResourceName";
prop.Handle = -1;
prop.Value <<= m_aClashingName;
Sequence<Any> seq(1);
@@ -202,7 +202,7 @@ XInteractionRequestImpl::getRequest()
excep.Arguments = seq;
excep.Classification = InteractionClassification_ERROR;
excep.Context = m_xOrigin;
- excep.Message = OUString( "the name contained invalid characters");
+ excep.Message = "the name contained invalid characters";
aAny <<= excep;
}
diff --git a/ucb/source/ucp/file/filrset.cxx b/ucb/source/ucp/file/filrset.cxx
index 457f4ca..8c6618f 100644
--- a/ucb/source/ucp/file/filrset.cxx
+++ b/ucb/source/ucp/file/filrset.cxx
@@ -226,7 +226,7 @@ void XResultSet_impl::rowCountChanged()
aOldValue = aNewValue-1;
}
beans::PropertyChangeEvent aEv;
- aEv.PropertyName = OUString("RowCount");
+ aEv.PropertyName = "RowCount";
aEv.Further = false;
aEv.PropertyHandle = -1;
aEv.OldValue <<= aOldValue;
@@ -251,7 +251,7 @@ void XResultSet_impl::isFinalChanged()
m_bRowCountFinal = true;
}
beans::PropertyChangeEvent aEv;
- aEv.PropertyName = OUString("IsRowCountFinal");
+ aEv.PropertyName = "IsRowCountFinal";
aEv.Further = false;
aEv.PropertyHandle = -1;
sal_Bool fval = false;
@@ -788,12 +788,12 @@ XResultSet_impl::getPropertySetInfo()
{
uno::Sequence< beans::Property > seq(2);
- seq[0].Name = OUString("RowCount");
+ seq[0].Name = "RowCount";
seq[0].Handle = -1;
seq[0].Type = getCppuType( static_cast< sal_Int32* >(0) );
seq[0].Attributes = beans::PropertyAttribute::READONLY;
- seq[0].Name = OUString("IsRowCountFinal");
+ seq[0].Name = "IsRowCountFinal";
seq[0].Handle = -1;
seq[0].Type = getCppuType( static_cast< sal_Bool* >(0) );
seq[0].Attributes = beans::PropertyAttribute::READONLY;
diff --git a/ucb/source/ucp/file/shell.cxx b/ucb/source/ucp/file/shell.cxx
index 3d30f78..1948f29 100644
--- a/ucb/source/ucp/file/shell.cxx
+++ b/ucb/source/ucp/file/shell.cxx
@@ -353,39 +353,39 @@ shell::shell( const uno::Reference< uno::XComponentContext >& rxContext,
| beans::PropertyAttribute::READONLY ) );
// Commands
- m_sCommandInfo[0].Name = OUString("getCommandInfo");
+ m_sCommandInfo[0].Name = "getCommandInfo";
m_sCommandInfo[0].Handle = -1;
m_sCommandInfo[0].ArgType = getCppuVoidType();
- m_sCommandInfo[1].Name = OUString("getPropertySetInfo");
+ m_sCommandInfo[1].Name = "getPropertySetInfo";
m_sCommandInfo[1].Handle = -1;
m_sCommandInfo[1].ArgType = getCppuVoidType();
- m_sCommandInfo[2].Name = OUString("getPropertyValues");
+ m_sCommandInfo[2].Name = "getPropertyValues";
m_sCommandInfo[2].Handle = -1;
m_sCommandInfo[2].ArgType = getCppuType( static_cast< uno::Sequence< beans::Property >* >( 0 ) );
- m_sCommandInfo[3].Name = OUString("setPropertyValues");
+ m_sCommandInfo[3].Name = "setPropertyValues";
m_sCommandInfo[3].Handle = -1;
m_sCommandInfo[3].ArgType = getCppuType( static_cast< uno::Sequence< beans::PropertyValue >* >( 0 ) );
- m_sCommandInfo[4].Name = OUString("open");
+ m_sCommandInfo[4].Name = "open";
m_sCommandInfo[4].Handle = -1;
m_sCommandInfo[4].ArgType = getCppuType( static_cast< OpenCommandArgument* >( 0 ) );
- m_sCommandInfo[5].Name = OUString("transfer");
+ m_sCommandInfo[5].Name = "transfer";
m_sCommandInfo[5].Handle = -1;
m_sCommandInfo[5].ArgType = getCppuType( static_cast< TransferInfo* >( 0 ) );
- m_sCommandInfo[6].Name = OUString("delete");
+ m_sCommandInfo[6].Name = "delete";
m_sCommandInfo[6].Handle = -1;
m_sCommandInfo[6].ArgType = getCppuType( static_cast< sal_Bool* >( 0 ) );
- m_sCommandInfo[7].Name = OUString("insert");
+ m_sCommandInfo[7].Name = "insert";
m_sCommandInfo[7].Handle = -1;
m_sCommandInfo[7].ArgType = getCppuType( static_cast< InsertCommandArgument* > ( 0 ) );
- m_sCommandInfo[7].Name = OUString("createNewContent");
+ m_sCommandInfo[7].Name = "createNewContent";
m_sCommandInfo[7].Handle = -1;
m_sCommandInfo[7].ArgType = getCppuType( static_cast< ucb::ContentInfo * > ( 0 ) );
@@ -1952,11 +1952,11 @@ void SAL_CALL shell::insertDefaultProperties( const OUString& aUnqPath )
/******************************************************************************/
-sal_Bool SAL_CALL shell::getUnqFromUrl( const OUString& Url,OUString& Unq )
+sal_Bool SAL_CALL shell::getUnqFromUrl( const OUString& Url, OUString& Unq )
{
if ( Url == "file:///" || Url == "file://localhost/" || Url == "file://127.0.0.1/" )
{
- Unq = OUString("file:///");
+ Unq = "file:///";
return false;
}
@@ -3037,14 +3037,14 @@ uno::Sequence< ucb::ContentInfo > shell::queryCreatableContentsInfo()
/*******************************************************************************/
/* */
-/* some misceancellous static functions */
+/* some miscellaneous static functions */
/* */
/*******************************************************************************/
void SAL_CALL
shell::getScheme( OUString& Scheme )
{
- Scheme = OUString("file");
+ Scheme = "file";
}
OUString SAL_CALL
diff --git a/ucb/source/ucp/ftp/ftpcontent.cxx b/ucb/source/ucp/ftp/ftpcontent.cxx
index eedc779..e98e0f8 100644
--- a/ucb/source/ucp/ftp/ftpcontent.cxx
+++ b/ucb/source/ucp/ftp/ftpcontent.cxx
@@ -361,7 +361,7 @@ Any SAL_CALL FTPContent::execute(
{
Sequence<Any> seq(1);
PropertyValue value;
- value.Name = OUString("Uri");
+ value.Name = "Uri";
value.Handle = -1;
value.Value <<= m_aFTPURL.ident(false,false);
value.State = PropertyState_DIRECT_VALUE;
@@ -396,7 +396,7 @@ Any SAL_CALL FTPContent::execute(
{
Sequence<Any> seq(1);
PropertyValue value;
- value.Name = OUString("Uri");
+ value.Name = "Uri";
value.Handle = -1;
value.Value <<= m_aFTPURL.ident(false,false);
value.State = PropertyState_DIRECT_VALUE;
@@ -514,7 +514,7 @@ Any SAL_CALL FTPContent::execute(
if(n) {
Sequence<Any> seq(1);
PropertyValue value;
- value.Name = OUString("Uri");
+ value.Name = "Uri";
value.Handle = -1;
value.Value <<= m_aFTPURL.ident(false,false);
value.State = PropertyState_DIRECT_VALUE;
@@ -733,7 +733,7 @@ void FTPContent::insert(const InsertCommandArgument& aInsertCommand,
if(m_bInserted && !m_bTitleSet) {
MissingPropertiesException excep;
excep.Properties.realloc(1);
- excep.Properties[0] = OUString("Title");
+ excep.Properties[0] = "Title";
Any aAny; aAny <<= excep;
ucbhelper::cancelCommandExecution(aAny,Env);
}
diff --git a/ucb/source/ucp/ftp/ftpresultsetbase.cxx b/ucb/source/ucp/ftp/ftpresultsetbase.cxx
index f220f09..8ace75c 100644
--- a/ucb/source/ucp/ftp/ftpresultsetbase.cxx
+++ b/ucb/source/ucp/ftp/ftpresultsetbase.cxx
@@ -502,12 +502,12 @@ ResultSetBase::getPropertySetInfo()
throw( uno::RuntimeException)
{
uno::Sequence< beans::Property > seq(2);
- seq[0].Name = OUString("RowCount");
+ seq[0].Name = "RowCount";
seq[0].Handle = -1;
seq[0].Type = getCppuType( static_cast< sal_Int32* >(0) );
seq[0].Attributes = beans::PropertyAttribute::READONLY;
- seq[1].Name = OUString("IsRowCountFinal");
+ seq[1].Name = "IsRowCountFinal";
seq[1].Handle = -1;
seq[1].Type = getCppuType( static_cast< sal_Bool* >(0) );
seq[1].Attributes = beans::PropertyAttribute::READONLY;
diff --git a/ucb/source/ucp/ftp/ftpurl.cxx b/ucb/source/ucp/ftp/ftpurl.cxx
index 60b6dcae..b71db5ae 100644
--- a/ucb/source/ucp/ftp/ftpurl.cxx
+++ b/ucb/source/ucp/ftp/ftpurl.cxx
@@ -576,7 +576,7 @@ OUString FTPURL::net_title() const
aNetTitle = decodePathSegment(m_aPathSegmentVec.back());
else
// must be root
- aNetTitle = OUString("/");
+ aNetTitle = "/";
try_more = false;
}
diff --git a/ucb/source/ucp/gio/gio_content.cxx b/ucb/source/ucp/gio/gio_content.cxx
index f2ae841..347ec40 100644
--- a/ucb/source/ucp/gio/gio_content.cxx
+++ b/ucb/source/ucp/gio/gio_content.cxx
@@ -706,7 +706,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
g_warning ("Set new name to '%s'", newName);
#endif
- aEvent.PropertyName = OUString("Title");
+ aEvent.PropertyName = "Title";
if (oldName)
aEvent.OldValue = uno::makeAny(OUString(oldName, strlen(oldName), RTL_TEXTENCODING_UTF8));
aEvent.NewValue = uno::makeAny(aNewTitle);
@@ -1340,7 +1340,7 @@ uno::Sequence< OUString > SAL_CALL Content::getSupportedServiceNames()
throw( uno::RuntimeException )
{
uno::Sequence< OUString > aSNS( 1 );
- aSNS.getArray()[ 0 ] = OUString("com.sun.star.ucb.GIOContent");
+ aSNS.getArray()[ 0 ] = "com.sun.star.ucb.GIOContent";
return aSNS;
}
diff --git a/ucb/source/ucp/gio/gio_datasupplier.cxx b/ucb/source/ucp/gio/gio_datasupplier.cxx
index bc4fb04..9deda7f 100644
--- a/ucb/source/ucp/gio/gio_datasupplier.cxx
+++ b/ucb/source/ucp/gio/gio_datasupplier.cxx
@@ -235,7 +235,7 @@ uno::Reference< sdbc::XRow > DataSupplier::queryPropertyValues( sal_uInt32 nInde
xContent, uno::UNO_QUERY_THROW );
sal_Int32 nCmdId( xCmdProc->createCommandIdentifier() );
ucb::Command aCmd;
- aCmd.Name = OUString("getPropertyValues");
+ aCmd.Name = "getPropertyValues";
aCmd.Handle = -1;
aCmd.Argument <<= getResultSet()->getProperties();
uno::Any aResult( xCmdProc->execute(
diff --git a/ucb/source/ucp/gvfs/gvfs_content.cxx b/ucb/source/ucp/gvfs/gvfs_content.cxx
index ef97acc..a2e5573 100644
--- a/ucb/source/ucp/gvfs/gvfs_content.cxx
+++ b/ucb/source/ucp/gvfs/gvfs_content.cxx
@@ -245,7 +245,7 @@ uno::Sequence< OUString > SAL_CALL Content::getSupportedServiceNames()
throw( uno::RuntimeException )
{
uno::Sequence< OUString > aSNS( 1 );
- aSNS.getArray()[ 0 ] = OUString( "com.sun.star.ucb.GnomeVFSContent" );
+ aSNS.getArray()[ 0 ] = "com.sun.star.ucb.GnomeVFSContent";
return aSNS;
}
@@ -538,7 +538,7 @@ OUString Content::getParentURL()
nPos1 = aURL.lastIndexOf( '/', nPos1 );
if ( nPos1 != -1 )
- aParentURL = OUString( aURL.copy( 0, nPos + 1 ) );
+ aParentURL = aURL.copy( 0, nPos + 1 );
#if OSL_DEBUG_LEVEL > 1
g_warning ("getParentURL '%s' -> '%s'",
@@ -805,7 +805,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
g_warning ("Set new name to '%s'", newName);
#endif
- aEvent.PropertyName = OUString("Title");
+ aEvent.PropertyName = "Title";
aEvent.OldValue = uno::makeAny( GnomeToOUString( newInfo.name ) );
aEvent.NewValue = uno::makeAny( aNewTitle );
aChanges.getArray()[ nChanged ] = aEvent;
diff --git a/ucb/source/ucp/hierarchy/hierarchycontent.cxx b/ucb/source/ucp/hierarchy/hierarchycontent.cxx
index b0fa90f..4c1bd9f 100644
--- a/ucb/source/ucp/hierarchy/hierarchycontent.cxx
+++ b/ucb/source/ucp/hierarchy/hierarchycontent.cxx
@@ -300,11 +300,11 @@ HierarchyContent::getSupportedServiceNames()
uno::Sequence< OUString > aSNS( 1 );
if ( m_eKind == LINK )
- aSNS.getArray()[ 0 ] = OUString( HIERARCHY_LINK_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = HIERARCHY_LINK_CONTENT_SERVICE_NAME;
else if ( m_eKind == FOLDER )
- aSNS.getArray()[ 0 ] = OUString( HIERARCHY_FOLDER_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = HIERARCHY_FOLDER_CONTENT_SERVICE_NAME;
else
- aSNS.getArray()[ 0 ] = OUString( HIERARCHY_ROOT_FOLDER_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = HIERARCHY_ROOT_FOLDER_CONTENT_SERVICE_NAME;
return aSNS;
}
@@ -1325,7 +1325,7 @@ uno::Sequence< uno::Any > HierarchyContent::setPropertyValues(
m_aProps.setTitle( aOldTitle );
m_aProps.setName ( aOldName );
- aOldTitle = aOldName = OUString();
+ aOldTitle = aOldName = "";
// Set error .
aRet[ nTitlePos ] <<= uno::Exception(
@@ -1336,7 +1336,7 @@ uno::Sequence< uno::Any > HierarchyContent::setPropertyValues(
if ( !aOldTitle.isEmpty() )
{
- aEvent.PropertyName = OUString("Title");
+ aEvent.PropertyName = "Title";
aEvent.OldValue = uno::makeAny( aOldTitle );
aEvent.NewValue = uno::makeAny( m_aProps.getTitle() );
@@ -1401,7 +1401,7 @@ void HierarchyContent::insert( sal_Int32 nNameClashResolve,
if ( m_aProps.getTitle().isEmpty() )
{
uno::Sequence< OUString > aProps( 1 );
- aProps[ 0 ] = OUString("Title");
+ aProps[ 0 ] = "Title";
ucbhelper::cancelCommandExecution(
uno::makeAny( ucb::MissingPropertiesException(
OUString(),
@@ -1807,7 +1807,7 @@ void HierarchyContent::transfer(
ucb::TransferInfo aInfo;
aInfo.MoveData = sal_False;
- aInfo.NewTitle = OUString();
+ aInfo.NewTitle = "";
aInfo.SourceURL = aChildId;
aInfo.NameClash = rInfo.NameClash;
@@ -1866,10 +1866,8 @@ HierarchyContentProperties::getCreatableContentsInfo() const
uno::Sequence< ucb::ContentInfo > aSeq( 2 );
// Folder.
- aSeq.getArray()[ 0 ].Type
- = OUString( HIERARCHY_FOLDER_CONTENT_TYPE );
- aSeq.getArray()[ 0 ].Attributes
- = ucb::ContentInfoAttribute::KIND_FOLDER;
+ aSeq.getArray()[ 0 ].Type = HIERARCHY_FOLDER_CONTENT_TYPE;
+ aSeq.getArray()[ 0 ].Attributes = ucb::ContentInfoAttribute::KIND_FOLDER;
uno::Sequence< beans::Property > aFolderProps( 1 );
aFolderProps.getArray()[ 0 ] = beans::Property(
@@ -1880,10 +1878,8 @@ HierarchyContentProperties::getCreatableContentsInfo() const
aSeq.getArray()[ 0 ].Properties = aFolderProps;
// Link.
- aSeq.getArray()[ 1 ].Type
- = OUString( HIERARCHY_LINK_CONTENT_TYPE );
- aSeq.getArray()[ 1 ].Attributes
- = ucb::ContentInfoAttribute::KIND_LINK;
+ aSeq.getArray()[ 1 ].Type = HIERARCHY_LINK_CONTENT_TYPE;
+ aSeq.getArray()[ 1 ].Attributes = ucb::ContentInfoAttribute::KIND_LINK;
uno::Sequence< beans::Property > aLinkProps( 2 );
aLinkProps.getArray()[ 0 ] = beans::Property(
diff --git a/ucb/source/ucp/hierarchy/hierarchyuri.cxx b/ucb/source/ucp/hierarchy/hierarchyuri.cxx
index 5f50aac..9eb1f88 100644
--- a/ucb/source/ucp/hierarchy/hierarchyuri.cxx
+++ b/ucb/source/ucp/hierarchy/hierarchyuri.cxx
@@ -50,13 +50,13 @@ void HierarchyUri::init() const
if ( !m_aUri.isEmpty() && m_aPath.isEmpty() )
{
// Note: Maybe it's a re-init, setUri only resets m_aPath!
- m_aService = m_aParentUri = m_aName = OUString();
+ m_aService = m_aParentUri = m_aName = "";
// URI must match at least: <sheme>:
if ( ( m_aUri.getLength() < HIERARCHY_URL_SCHEME_LENGTH + 1 ) )
{
// error, but remember that we did a init().
- m_aPath = OUString("/");
+ m_aPath = "/";
return;
}
@@ -76,7 +76,7 @@ void HierarchyUri::init() const
{
// root folder URI without path and service specifier.
m_aUri += "//" DEFAULT_DATA_SOURCE_SERVICE "/";
- m_aService = OUString( DEFAULT_DATA_SOURCE_SERVICE );
+ m_aService = DEFAULT_DATA_SOURCE_SERVICE ;
nPos = m_aUri.getLength() - 1;
}
@@ -86,7 +86,7 @@ void HierarchyUri::init() const
{
// root folder URI without service specifier.
m_aUri += "/" DEFAULT_DATA_SOURCE_SERVICE "/";
- m_aService = OUString( DEFAULT_DATA_SOURCE_SERVICE );
+ m_aService = DEFAULT_DATA_SOURCE_SERVICE;
nPos = m_aUri.getLength() - 1;
}
@@ -99,7 +99,7 @@ void HierarchyUri::init() const
HIERARCHY_URL_SCHEME_LENGTH + 2,
0,
OUString( "/" DEFAULT_DATA_SOURCE_SERVICE "/" ) );
- m_aService = OUString( DEFAULT_DATA_SOURCE_SERVICE );
+ m_aService = DEFAULT_DATA_SOURCE_SERVICE;
nPos
= HIERARCHY_URL_SCHEME_LENGTH + 3 + m_aService.getLength();
@@ -116,7 +116,7 @@ void HierarchyUri::init() const
if ( nStart == m_aUri.getLength() )
{
// error, but remember that we did a init().
- m_aPath = OUString("/");
+ m_aPath = "/";
return;
}
@@ -126,7 +126,7 @@ void HierarchyUri::init() const
nStart ) != -1 )
{
// error, but remember that we did a init().
- m_aPath = OUString("/");
+ m_aPath = "/";
return;
}
@@ -136,7 +136,7 @@ void HierarchyUri::init() const
if ( nEnd == nStart )
{
// error, but remember that we did a init().
- m_aPath = OUString("/");
+ m_aPath = "/";
return;
}
@@ -180,7 +180,7 @@ void HierarchyUri::init() const
else
{
// error, but remember that we did a init().
- m_aPath = OUString("/");
+ m_aPath = "/";
}
}
}
diff --git a/ucb/source/ucp/package/pkgcontent.cxx b/ucb/source/ucp/package/pkgcontent.cxx
index b8eb22e..34c5af5 100644
--- a/ucb/source/ucp/package/pkgcontent.cxx
+++ b/ucb/source/ucp/package/pkgcontent.cxx
@@ -417,9 +417,9 @@ uno::Sequence< OUString > SAL_CALL Content::getSupportedServiceNames()
{
uno::Sequence< OUString > aSNS( 1 );
if ( isFolder() )
- aSNS.getArray()[ 0 ] = OUString( PACKAGE_FOLDER_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = PACKAGE_FOLDER_CONTENT_SERVICE_NAME;
else
- aSNS.getArray()[ 0 ] = OUString( PACKAGE_STREAM_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = PACKAGE_STREAM_CONTENT_SERVICE_NAME;
return aSNS;
}
@@ -1390,7 +1390,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
else
{
// Do not set new title!
- aNewTitle = OUString();
+ aNewTitle = "";
// Set error .
aRet[ nTitlePos ] <<= uno::Exception(
@@ -1401,7 +1401,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( !aNewTitle.isEmpty() )
{
- aEvent.PropertyName = OUString("Title");
+ aEvent.PropertyName = "Title";
aEvent.OldValue = uno::makeAny( m_aProps.aTitle );
aEvent.NewValue = uno::makeAny( aNewTitle );
@@ -2041,7 +2041,7 @@ void Content::transfer(
ucb::TransferInfo aInfo;
aInfo.MoveData = sal_False;
- aInfo.NewTitle = OUString();
+ aInfo.NewTitle = "";
aInfo.SourceURL = aChildId;
aInfo.NameClash = rInfo.NameClash;
diff --git a/ucb/source/ucp/tdoc/tdoc_content.cxx b/ucb/source/ucp/tdoc/tdoc_content.cxx
index 54543c3..6a2acc7 100644
--- a/ucb/source/ucp/tdoc/tdoc_content.cxx
+++ b/ucb/source/ucp/tdoc/tdoc_content.cxx
@@ -314,13 +314,13 @@ uno::Sequence< OUString > SAL_CALL Content::getSupportedServiceNames()
uno::Sequence< OUString > aSNS( 1 );
if ( m_aProps.getType() == STREAM )
- aSNS.getArray()[ 0 ] = OUString( TDOC_STREAM_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = TDOC_STREAM_CONTENT_SERVICE_NAME;
else if ( m_aProps.getType() == FOLDER )
- aSNS.getArray()[ 0 ] = OUString( TDOC_FOLDER_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = TDOC_FOLDER_CONTENT_SERVICE_NAME;
else if ( m_aProps.getType() == DOCUMENT )
- aSNS.getArray()[ 0 ] = OUString( TDOC_DOCUMENT_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = TDOC_DOCUMENT_CONTENT_SERVICE_NAME;
else
- aSNS.getArray()[ 0 ] = OUString( TDOC_ROOT_CONTENT_SERVICE_NAME );
+ aSNS.getArray()[ 0 ] = TDOC_ROOT_CONTENT_SERVICE_NAME;
return aSNS;
}
@@ -1350,7 +1350,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
{
// Roll-back.
m_aProps.setTitle( aOldTitle );
- aOldTitle = OUString();
+ aOldTitle = "";
// Set error .
aRet[ nTitlePos ] <<= uno::Exception(
@@ -1361,7 +1361,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( !aOldTitle.isEmpty() )
{
- aEvent.PropertyName = OUString("Title");
+ aEvent.PropertyName = "Title";
aEvent.OldValue = uno::makeAny( aOldTitle );
aEvent.NewValue = uno::makeAny( m_aProps.getTitle() );
@@ -2953,10 +2953,8 @@ ContentProperties::getCreatableContentsInfo() const
uno::Sequence< ucb::ContentInfo > aSeq( 1 );
// Folder.
- aSeq.getArray()[ 0 ].Type
- = OUString( TDOC_FOLDER_CONTENT_TYPE );
- aSeq.getArray()[ 0 ].Attributes
- = ucb::ContentInfoAttribute::KIND_FOLDER;
+ aSeq.getArray()[ 0 ].Type = TDOC_FOLDER_CONTENT_TYPE;
+ aSeq.getArray()[ 0 ].Attributes = ucb::ContentInfoAttribute::KIND_FOLDER;
aSeq.getArray()[ 0 ].Properties = aProps;
return aSeq;
@@ -2967,15 +2965,13 @@ ContentProperties::getCreatableContentsInfo() const
uno::Sequence< ucb::ContentInfo > aSeq( 2 );
// Folder.
- aSeq.getArray()[ 0 ].Type
- = OUString( TDOC_FOLDER_CONTENT_TYPE );
+ aSeq.getArray()[ 0 ].Type = TDOC_FOLDER_CONTENT_TYPE;
aSeq.getArray()[ 0 ].Attributes
= ucb::ContentInfoAttribute::KIND_FOLDER;
aSeq.getArray()[ 0 ].Properties = aProps;
// Stream.
- aSeq.getArray()[ 1 ].Type
- = OUString( TDOC_STREAM_CONTENT_TYPE );
+ aSeq.getArray()[ 1 ].Type = TDOC_STREAM_CONTENT_TYPE;
aSeq.getArray()[ 1 ].Attributes
= ucb::ContentInfoAttribute::INSERT_WITH_INPUTSTREAM
| ucb::ContentInfoAttribute::KIND_DOCUMENT;
diff --git a/ucb/source/ucp/tdoc/tdoc_uri.cxx b/ucb/source/ucp/tdoc/tdoc_uri.cxx
index 24110bf..f868a60 100644
--- a/ucb/source/ucp/tdoc/tdoc_uri.cxx
+++ b/ucb/source/ucp/tdoc/tdoc_uri.cxx
@@ -114,7 +114,7 @@ void Uri::init() const
if ( nSlash != - 1 )
m_aInternalPath = m_aPath.copy( nSlash );
else
- m_aInternalPath = OUString("/");
+ m_aInternalPath = "/";
}
m_eState = VALID;
diff --git a/ucb/source/ucp/webdav-neon/DAVProperties.cxx b/ucb/source/ucp/webdav-neon/DAVProperties.cxx
index 7abdb6f..313462e 100644
--- a/ucb/source/ucp/webdav-neon/DAVProperties.cxx
+++ b/ucb/source/ucp/webdav-neon/DAVProperties.cxx
@@ -130,7 +130,7 @@ void DAVProperties::createUCBPropName( const char * nspace,
DAVProperties::GETETAG.matchIgnoreAsciiCase( aName, 4 ) ||
DAVProperties::GETLASTMODIFIED.matchIgnoreAsciiCase( aName, 4 ) ||
DAVProperties::SOURCE.matchIgnoreAsciiCase( aName, 4 ) )
- aNameSpace = OUString( "DAV:" );
+ aNameSpace = "DAV:";
}
// Note: Concatenating strings BEFORE comparing against known namespaces
@@ -156,11 +156,7 @@ void DAVProperties::createUCBPropName( const char * nspace,
else
{
// Create property name that encodes, namespace and name ( XML ).
- rFullName = OUString("<prop:");
- rFullName += aName;
- rFullName += OUString( " xmlns:prop=\"" );
- rFullName += aNameSpace;
- rFullName += OUString( "\">" );
+ rFullName = "<prop:" + aName + " xmlns:prop=\"" + aNameSpace + "\">";
}
}
diff --git a/ucb/source/ucp/webdav-neon/webdavcontent.cxx b/ucb/source/ucp/webdav-neon/webdavcontent.cxx
index f117a9b..bff41ad 100644
--- a/ucb/source/ucp/webdav-neon/webdavcontent.cxx
+++ b/ucb/source/ucp/webdav-neon/webdavcontent.cxx
@@ -345,8 +345,7 @@ uno::Sequence< OUString > SAL_CALL Content::getSupportedServiceNames()
throw( uno::RuntimeException )
{
uno::Sequence< OUString > aSNS( 1 );
- aSNS.getArray()[ 0 ]
- = OUString( WEBDAV_CONTENT_SERVICE_NAME );
+ aSNS[ 0 ] = WEBDAV_CONTENT_SERVICE_NAME;
return aSNS;
}
@@ -1030,8 +1029,7 @@ Content::queryCreatableContentsInfo()
uno::Sequence< ucb::ContentInfo > aSeq( 2 );
// document.
- aSeq.getArray()[ 0 ].Type
- = OUString( WEBDAV_CONTENT_TYPE );
+ aSeq.getArray()[ 0 ].Type = WEBDAV_CONTENT_TYPE;
aSeq.getArray()[ 0 ].Attributes
= ucb::ContentInfoAttribute::INSERT_WITH_INPUTSTREAM
| ucb::ContentInfoAttribute::KIND_DOCUMENT;
@@ -1045,8 +1043,7 @@ Content::queryCreatableContentsInfo()
aSeq.getArray()[ 0 ].Properties = aDocProps;
// folder.
- aSeq.getArray()[ 1 ].Type
- = OUString( WEBDAV_COLLECTION_TYPE );
+ aSeq.getArray()[ 1 ].Type = WEBDAV_COLLECTION_TYPE;
aSeq.getArray()[ 1 ].Attributes
= ucb::ContentInfoAttribute::KIND_FOLDER;
@@ -1890,7 +1887,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
else
{
// Do not set new title!
- aNewTitle = OUString();
+ aNewTitle = "";
// Set error .
aRet[ nTitlePos ] <<= uno::Exception(
@@ -1901,7 +1898,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
catch ( DAVException const & e )
{
// Do not set new title!
- aNewTitle = OUString();
+ aNewTitle = "";
// Set error .
aRet[ nTitlePos ] <<= MapDAVException( e, sal_True );
@@ -1912,7 +1909,7 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
{
osl::Guard< osl::Mutex > aGuard( m_aMutex );
- aEvent.PropertyName = OUString("Title");
+ aEvent.PropertyName = "Title";
aEvent.OldValue = uno::makeAny( aOldTitle );
aEvent.NewValue = uno::makeAny( aNewTitle );
@@ -2289,7 +2286,7 @@ void Content::insert(
OSL_FAIL( "Content::insert - Title missing!" );
uno::Sequence< OUString > aProps( 1 );
- aProps[ 0 ] = OUString("Title");
+ aProps[ 0 ] = "Title";
ucbhelper::cancelCommandExecution(
uno::makeAny( ucb::MissingPropertiesException(
OUString(),
@@ -2595,7 +2592,7 @@ void Content::transfer(
if ( aTitle == "/" )
{
// kso: ???
- aTitle = OUString();
+ aTitle = "";
}
targetURI.AppendPath( aTitle );
@@ -2943,7 +2940,7 @@ sal_Bool Content::isFolder(
}
uno::Sequence< beans::Property > aProperties( 1 );
- aProperties[ 0 ].Name = OUString("IsFolder");
+ aProperties[ 0 ].Name = "IsFolder";
aProperties[ 0 ].Handle = -1;
uno::Reference< sdbc::XRow > xRow( getPropertyValues( aProperties, xEnv ) );
if ( xRow.is() )
@@ -3210,10 +3207,10 @@ Content::ResourceType Content::getResourceType(
std::vector< DAVResource > resources;
std::vector< OUString > aPropNames;
uno::Sequence< beans::Property > aProperties( 5 );
- aProperties[ 0 ].Name = OUString("IsFolder");
- aProperties[ 1 ].Name = OUString("IsDocument");
- aProperties[ 2 ].Name = OUString("IsReadOnly");
- aProperties[ 3 ].Name = OUString("MediaType");
+ aProperties[ 0 ].Name = "IsFolder";
+ aProperties[ 1 ].Name = "IsDocument";
+ aProperties[ 2 ].Name = "IsReadOnly";
+ aProperties[ 3 ].Name = "MediaType";
aProperties[ 4 ].Name = DAVProperties::SUPPORTEDLOCK;
ContentProperties::UCBNamesToDAVNames( aProperties, aPropNames );
diff --git a/ucb/workben/ucb/ucbdemo.cxx b/ucb/workben/ucb/ucbdemo.cxx
index 6c2392b..bb0631e 100644
--- a/ucb/workben/ucb/ucbdemo.cxx
+++ b/ucb/workben/ucb/ucbdemo.cxx
@@ -907,18 +907,15 @@ void UcbContent::open( const OUString & rName, const OUString& rInput,
return;
}
aArgument.Properties.realloc(5);
- aArgument.Properties[0].Name = OUString("Title");
+ aArgument.Properties[0].Name = "Title";
aArgument.Properties[0].Handle = -1;
- aArgument.Properties[1].Name
- = OUString("DateCreated");
+ aArgument.Properties[1].Name = "DateCreated";
aArgument.Properties[1].Handle = -1;
- aArgument.Properties[2].Name = OUString("Size");
+ aArgument.Properties[2].Name = "Size";
aArgument.Properties[2].Handle = -1;
- aArgument.Properties[3].Name
- = OUString("IsFolder");
+ aArgument.Properties[3].Name = "IsFolder";
aArgument.Properties[3].Handle = -1;
- aArgument.Properties[4].Name
- = OUString("IsDocument");
+ aArgument.Properties[4].Name = "IsDocument";
aArgument.Properties[4].Handle = -1;
aArg <<= aArgument;
}
@@ -931,19 +928,19 @@ void UcbContent::open( const OUString & rName, const OUString& rInput,
// Property values which shall be in the result set...
uno::Sequence< beans::Property > aProps( 5 );
beans::Property* pProps = aProps.getArray();
- pProps[ 0 ].Name = OUString("Title");
+ pProps[ 0 ].Name = "Title";
pProps[ 0 ].Handle = -1; // Important!
/**/ pProps[ 0 ].Type = getCppuType(static_cast< OUString * >(0));
// HACK for sorting...
- pProps[ 1 ].Name = OUString("DateCreated");
+ pProps[ 1 ].Name = "DateCreated";
pProps[ 1 ].Handle = -1; // Important!
- pProps[ 2 ].Name = OUString("Size");
+ pProps[ 2 ].Name = "Size";
pProps[ 2 ].Handle = -1; // Important!
- pProps[ 3 ].Name = OUString("IsFolder");
+ pProps[ 3 ].Name = "IsFolder";
pProps[ 3 ].Handle = -1; // Important!
/**/ pProps[ 3 ].Type = getCppuType(static_cast< sal_Bool * >(0));
// HACK for sorting...
- pProps[ 4 ].Name = OUString("IsDocument");
+ pProps[ 4 ].Name = "IsDocument";
pProps[ 4 ].Handle = -1; // Important!
aOpenArg.Properties = aProps;
@@ -2204,7 +2201,7 @@ IMPL_LINK( MyWin, ToolBarHandler, ToolBox*, pToolBox )
uno::Any aArgument;
if (nItemId == MYWIN_ITEMID_OFFLINE)
{
- aName = OUString("goOffline");
+ aName = "goOffline";
uno::Sequence<
uno::Reference< ucb::XContentIdentifier > >
@@ -2215,7 +2212,7 @@ IMPL_LINK( MyWin, ToolBarHandler, ToolBox*, pToolBox )
aArgument <<= aIdentifiers;
}
else
- aName = OUString("goOnline");
+ aName = "goOnline";
UcbCommandProcessor(m_aUCB, xProcessor, m_pOutEdit).
executeCommand(aName, aArgument);
@@ -2268,7 +2265,7 @@ void MyApp::Main()
{
aConfigurationKey1
= aParam.Copy(RTL_CONSTASCII_LENGTH("-key="));
- aConfigurationKey2 = OUString();
+ aConfigurationKey2 = "";
}
else
{
commit f6ad2b7a52266e7a4d039f9ba557476e6881fa5f
Author: Noel Grandin <noel at peralex.com>
Date: Thu Oct 31 14:40:44 2013 +0200
remove unnecessary use of OUString constructor in UCBHELPER module
Change-Id: I3e3cfc69c14a300f330264ae40c135e8135adb97
diff --git a/ucbhelper/source/client/content.cxx b/ucbhelper/source/client/content.cxx
index e36207b..91cea87 100644
--- a/ucbhelper/source/client/content.cxx
+++ b/ucbhelper/source/client/content.cxx
@@ -393,7 +393,7 @@ Reference< XCommandInfo > Content::getCommands()
throw( CommandAbortedException, RuntimeException, Exception )
{
Command aCommand;
- aCommand.Name = OUString("getCommandInfo");
+ aCommand.Name = "getCommandInfo";
aCommand.Handle = -1; // n/a
aCommand.Argument = Any();
@@ -409,7 +409,7 @@ Reference< XPropertySetInfo > Content::getProperties()
throw( CommandAbortedException, RuntimeException, Exception )
{
Command aCommand;
- aCommand.Name = OUString("getPropertySetInfo");
+ aCommand.Name = "getPropertySetInfo";
aCommand.Handle = -1; // n/a
aCommand.Argument = Any();
@@ -489,7 +489,7 @@ Reference< XRow > Content::getPropertyValuesInterface(
}
Command aCommand;
- aCommand.Name = OUString("getPropertyValues");
+ aCommand.Name = "getPropertyValues";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aProps;
@@ -537,7 +537,7 @@ Sequence< Any > Content::setPropertyValues(
}
Command aCommand;
- aCommand.Name = OUString("setPropertyValues");
+ aCommand.Name = "setPropertyValues";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aProps;
@@ -587,7 +587,7 @@ Any Content::createCursorAny( const Sequence< OUString >& rPropertyNames,
aArg.Properties = aProps;
Command aCommand;
- aCommand.Name = OUString("open");
+ aCommand.Name = "open";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -706,7 +706,7 @@ Reference< XInputStream > Content::openStream()
aArg.Properties = Sequence< Property >( 0 ); // unused
Command aCommand;
- aCommand.Name = OUString("open");
+ aCommand.Name = "open";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -731,7 +731,7 @@ Reference< XInputStream > Content::openStreamNoLock()
aArg.Properties = Sequence< Property >( 0 ); // unused
Command aCommand;
- aCommand.Name = OUString("open");
+ aCommand.Name = "open";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -756,7 +756,7 @@ Reference< XStream > Content::openWriteableStream()
aArg.Properties = Sequence< Property >( 0 ); // unused
Command aCommand;
- aCommand.Name = OUString("open");
+ aCommand.Name = "open";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -781,7 +781,7 @@ Reference< XStream > Content::openWriteableStreamNoLock()
aArg.Properties = Sequence< Property >( 0 ); // unused
Command aCommand;
- aCommand.Name = OUString("open");
+ aCommand.Name = "open";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -804,7 +804,7 @@ sal_Bool Content::openStream( const Reference< XActiveDataSink >& rSink )
aArg.Properties = Sequence< Property >( 0 ); // unused
Command aCommand;
- aCommand.Name = OUString("open");
+ aCommand.Name = "open";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -827,7 +827,7 @@ sal_Bool Content::openStream( const Reference< XOutputStream >& rStream )
aArg.Properties = Sequence< Property >( 0 ); // unused
Command aCommand;
- aCommand.Name = OUString("open");
+ aCommand.Name = "open";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -846,7 +846,7 @@ void Content::writeStream( const Reference< XInputStream >& rStream,
aArg.ReplaceExisting = bReplaceExisting;
Command aCommand;
- aCommand.Name = OUString("insert");
+ aCommand.Name = "insert";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aArg;
@@ -908,7 +908,7 @@ sal_Bool Content::insertNewContent( const OUString& rContentType,
aInfo.Attributes = 0;
Command aCommand;
- aCommand.Name = OUString("createNewContent");
+ aCommand.Name = "createNewContent";
aCommand.Handle = -1; // n/a
aCommand.Argument <<= aInfo;
@@ -990,7 +990,7 @@ sal_Bool Content::transferContent( const Content& rSourceContent,
case InsertOperation_CHECKIN:
eTransOp = TransferCommandOperation_COPY;
- sCommand = OUString( "checkin" );
+ sCommand = "checkin";
bCheckIn = true;
break;
@@ -1180,7 +1180,7 @@ void Content_Impl::disposing( const EventObject& Source )
xContent = m_xContent;
- m_aURL = OUString();
+ m_aURL = "";
m_xCommandProcessor = 0;
m_xContent = 0;
}
@@ -1301,7 +1301,7 @@ void Content_Impl::inserted()
{
// URL might have changed during 'insert' => recalculate in next getURL()
osl::MutexGuard aGuard( m_aMutex );
- m_aURL = OUString();
+ m_aURL = "";
}
//=========================================================================
diff --git a/ucbhelper/source/client/proxydecider.cxx b/ucbhelper/source/client/proxydecider.cxx
index 114c12a..55a8e7b 100644
--- a/ucbhelper/source/client/proxydecider.cxx
+++ b/ucbhelper/source/client/proxydecider.cxx
@@ -711,7 +711,7 @@ void InternetProxyDecider_Impl::setNoProxyList(
if ( nColonPos == -1 )
{
// No port given, server pattern equals current token
- aPort = OUString("*");
+ aPort = "*";
if ( aToken.indexOf( '*' ) == -1 )
{
// pattern describes exactly one server
commit 5fca9e5bfce57875e5d93245d6d1219d0a0e86c1
Author: Noel Grandin <noel at peralex.com>
Date: Thu Oct 31 14:38:55 2013 +0200
remove unnecessary use of OUString constructor in UNOTOOLS module
Change-Id: Iad166e6b9ce0877200bd58c388b3914b15167196
diff --git a/unotools/source/config/eventcfg.cxx b/unotools/source/config/eventcfg.cxx
index ed18ff1..f0e6966 100644
--- a/unotools/source/config/eventcfg.cxx
+++ b/unotools/source/config/eventcfg.cxx
@@ -116,7 +116,7 @@ GlobalEventConfig_Impl::GlobalEventConfig_Impl()
// Enable notification mechanism of our baseclass.
// We need it to get information about changes outside these class on our used configuration keys! */
Sequence< OUString > aNotifySeq( 1 );
- aNotifySeq[0] = OUString( "Events" );
+ aNotifySeq[0] = "Events";
EnableNotification( aNotifySeq, sal_True );
}
@@ -256,9 +256,9 @@ Any SAL_CALL GlobalEventConfig_Impl::getByName( const OUString& aName ) throw (c
{
Any aRet;
Sequence< beans::PropertyValue > props(2);
- props[0].Name = OUString("EventType");
+ props[0].Name = "EventType";
props[0].Value <<= OUString("Script");
- props[1].Name = OUString("Script");
+ props[1].Name = "Script";
EventBindingHash::const_iterator it = m_eventBindingHash.find( aName );
if( it != m_eventBindingHash.end() )
{
diff --git a/unotools/source/config/lingucfg.cxx b/unotools/source/config/lingucfg.cxx
index 8f1e767..0f0344a 100644
--- a/unotools/source/config/lingucfg.cxx
+++ b/unotools/source/config/lingucfg.cxx
@@ -1100,7 +1100,7 @@ uno::Reference< util::XChangesBatch > SvtLinguConfig::GetMainUpdateAccess() cons
// get configuration update access
beans::PropertyValue aValue;
- aValue.Name = OUString("nodepath");
+ aValue.Name = "nodepath";
aValue.Value = uno::makeAny(OUString("org.openoffice.Office.Linguistic"));
uno::Sequence< uno::Any > aProps(1);
aProps[0] <<= aValue;
diff --git a/unotools/source/i18n/localedatawrapper.cxx b/unotools/source/i18n/localedatawrapper.cxx
index 09a230e..c9fcf63 100644
--- a/unotools/source/i18n/localedatawrapper.cxx
+++ b/unotools/source/i18n/localedatawrapper.cxx
@@ -120,20 +120,20 @@ const ::com::sun::star::lang::Locale& LocaleDataWrapper::getMyLocale() const
void LocaleDataWrapper::invalidateData()
{
- aCurrSymbol = OUString();
- aCurrBankSymbol = OUString();
+ aCurrSymbol = "";
+ aCurrBankSymbol = "";
nDateFormat = nLongDateFormat = nDateFormatInvalid;
nCurrPositiveFormat = nCurrNegativeFormat = nCurrDigits = nCurrFormatInvalid;
if ( bLocaleDataItemValid )
{
for (sal_Int32 j=0; j<LocaleItem::COUNT; ++j)
- aLocaleItem[j] = OUString();
+ aLocaleItem[j] = "";
bLocaleDataItemValid = sal_False;
}
if ( bReservedWordValid )
{
for ( sal_Int16 j=0; j<reservedWords::COUNT; ++j )
- aReservedWord[j] = OUString();
+ aReservedWord[j] = "";
bReservedWordValid = sal_False;
}
xDefaultCalendar.reset();
@@ -595,7 +595,7 @@ void LocaleDataWrapper::getCurrSymbolsImpl()
{
if (areChecksEnabled())
outputCheckMessage(OUString("LocaleDataWrapper::getCurrSymbolsImpl: no currency at all, using ShellsAndPebbles"));
- aCurrSymbol = OUString("ShellsAndPebbles");
+ aCurrSymbol = "ShellsAndPebbles";
aCurrBankSymbol = aCurrSymbol;
nCurrPositiveFormat = nCurrNegativeFormat = nCurrFormatDefault;
nCurrDigits = 2;
diff --git a/unotools/source/ucbhelper/ucbhelper.cxx b/unotools/source/ucbhelper/ucbhelper.cxx
index 97cc3c7..f20aaee 100644
--- a/unotools/source/ucbhelper/ucbhelper.cxx
+++ b/unotools/source/ucbhelper/ucbhelper.cxx
@@ -86,7 +86,7 @@ std::vector<OUString> getContents(OUString const & url) {
std::vector<OUString> cs;
ucbhelper::Content c(content(url));
css::uno::Sequence<OUString> args(1);
- args[0] = OUString("Title");
+ args[0] = "Title";
css::uno::Reference<css::sdbc::XResultSet> res(
c.createCursor(args, ucbhelper::INCLUDE_FOLDERS_AND_DOCUMENTS),
css::uno::UNO_SET_THROW);
@@ -250,7 +250,7 @@ bool utl::UCBContentHelper::MakeFolder(
continue;
}
css::uno::Sequence<OUString> keys(1);
- keys[0] = OUString("Title");
+ keys[0] = "Title";
css::uno::Sequence<css::uno::Any> values(1);
values[0] <<= title;
if (parent.insertNewContent(info[i].Type, keys, values, result))
diff --git a/unotools/source/ucbhelper/ucblockbytes.cxx b/unotools/source/ucbhelper/ucblockbytes.cxx
index 5c7f78f..6e9d826 100644
--- a/unotools/source/ucbhelper/ucblockbytes.cxx
+++ b/unotools/source/ucbhelper/ucblockbytes.cxx
@@ -1621,7 +1621,7 @@ UcbLockBytesRef UcbLockBytes::CreateLockBytes( const Reference < XContent >& xCo
{
Reference < XCommandProcessor > xProcessor( xContent, UNO_QUERY );
Command aCommand;
- aCommand.Name = OUString("setPropertyValues");
+ aCommand.Name = "setPropertyValues";
aCommand.Handle = -1; /* unknown */
aCommand.Argument <<= rProps;
xProcessor->execute( aCommand, 0, Reference < XCommandEnvironment >() );
@@ -1632,7 +1632,7 @@ UcbLockBytesRef UcbLockBytes::CreateLockBytes( const Reference < XContent >& xCo
aArgument.Mode = OpenMode::DOCUMENT;
Command aCommand;
- aCommand.Name = OUString( "open" );
+ aCommand.Name = "open";
aCommand.Argument <<= aArgument;
Reference< XProgressHandler > xProgressHdl = new ProgressHandler_Impl( LINK( &xLockBytes, UcbLockBytes, DataAvailHdl ) );
More information about the Libreoffice-commits
mailing list