summaryrefslogtreecommitdiff
path: root/ucb
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-02-24 11:22:18 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-02-28 10:17:47 +0000
commit198c41c4fe8be4ce8a6ddab43ae0c5f17a4889ac (patch)
tree041d55126e9770b81f68fadfaaa69e82313786b3 /ucb
parentd3981b3e8c021ee03a2ca7103a73e56cca18df81 (diff)
new loplugin unoany
Change-Id: I5d6c4a67cb2a09e7cd5bd620c6b262d188701b89 Reviewed-on: https://gerrit.libreoffice.org/34714 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'ucb')
-rw-r--r--ucb/source/core/FileAccess.cxx4
-rw-r--r--ucb/source/core/ucbcmds.cxx2
-rw-r--r--ucb/source/ucp/gio/gio_content.cxx6
-rw-r--r--ucb/source/ucp/hierarchy/hierarchycontent.cxx10
-rw-r--r--ucb/source/ucp/package/pkgcontent.cxx21
-rw-r--r--ucb/source/ucp/tdoc/tdoc_content.cxx4
-rw-r--r--ucb/source/ucp/webdav-neon/webdavcontent.cxx6
7 files changed, 25 insertions, 28 deletions
diff --git a/ucb/source/core/FileAccess.cxx b/ucb/source/core/FileAccess.cxx
index 0752bcd309af..9f8f4c7888b1 100644
--- a/ucb/source/core/FileAccess.cxx
+++ b/ucb/source/core/FileAccess.cxx
@@ -374,7 +374,7 @@ void OFileAccess::createFolder( const OUString& NewFolderURL )
Sequence<OUString> aNames { "Title" };
Sequence< Any > aValues(1);
Any* pValues = aValues.getArray();
- pValues[0] = makeAny( OUString( aTitle ) );
+ pValues[0] <<= aTitle;
ucbhelper::Content aNew;
try
@@ -634,7 +634,7 @@ bool OFileAccess::createNewFile( const OUString & rParentURL,
Sequence<OUString> aNames { "Title" };
Sequence< Any > aValues(1);
Any* pValues = aValues.getArray();
- pValues[0] = makeAny( OUString( rTitle ) );
+ pValues[0] <<= rTitle;
try
{
diff --git a/ucb/source/core/ucbcmds.cxx b/ucb/source/core/ucbcmds.cxx
index 2f061473e0bb..f288a60aec18 100644
--- a/ucb/source/core/ucbcmds.cxx
+++ b/ucb/source/core/ucbcmds.cxx
@@ -445,7 +445,7 @@ bool setTitle(
uno::Sequence< beans::PropertyValue > aPropValues( 1 );
aPropValues[ 0 ].Name = "Title";
aPropValues[ 0 ].Handle = -1;
- aPropValues[ 0 ].Value = uno::makeAny( rNewTitle );
+ aPropValues[ 0 ].Value <<= rNewTitle;
ucb::Command aSetPropsCommand(
"setPropertyValues",
diff --git a/ucb/source/ucp/gio/gio_content.cxx b/ucb/source/ucp/gio/gio_content.cxx
index 646cd2a2784f..5402de23ad52 100644
--- a/ucb/source/ucp/gio/gio_content.cxx
+++ b/ucb/source/ucp/gio/gio_content.cxx
@@ -141,7 +141,7 @@ OUString SAL_CALL Content::getContentType()
#define EXCEPT(aExcept) \
do { \
if (bThrow) throw aExcept;\
- aRet = uno::makeAny( aExcept );\
+ aRet <<= aExcept;\
} while(false)
uno::Any convertToException(GError *pError, const uno::Reference< uno::XInterface >& rContext, bool bThrow)
@@ -722,8 +722,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
aEvent.PropertyName = "Title";
if (oldName)
- aEvent.OldValue = uno::makeAny(OUString(oldName, strlen(oldName), RTL_TEXTENCODING_UTF8));
- aEvent.NewValue = uno::makeAny(aNewTitle);
+ aEvent.OldValue <<= OUString(oldName, strlen(oldName), RTL_TEXTENCODING_UTF8);
+ aEvent.NewValue <<= aNewTitle;
aChanges.getArray()[ nChanged ] = aEvent;
nTitlePos = nChanged++;
diff --git a/ucb/source/ucp/hierarchy/hierarchycontent.cxx b/ucb/source/ucp/hierarchy/hierarchycontent.cxx
index 141d3ea6da52..012716989b52 100644
--- a/ucb/source/ucp/hierarchy/hierarchycontent.cxx
+++ b/ucb/source/ucp/hierarchy/hierarchycontent.cxx
@@ -1184,10 +1184,8 @@ uno::Sequence< uno::Any > HierarchyContent::setPropertyValues(
if ( aNewValue != m_aProps.getTargetURL() )
{
aEvent.PropertyName = rValue.Name;
- aEvent.OldValue
- = uno::makeAny( m_aProps.getTargetURL() );
- aEvent.NewValue
- = uno::makeAny( aNewValue );
+ aEvent.OldValue <<= m_aProps.getTargetURL();
+ aEvent.NewValue <<= aNewValue;
aChanges.getArray()[ nChanged ] = aEvent;
@@ -1309,8 +1307,8 @@ uno::Sequence< uno::Any > HierarchyContent::setPropertyValues(
if ( !aOldTitle.isEmpty() )
{
aEvent.PropertyName = "Title";
- aEvent.OldValue = uno::makeAny( aOldTitle );
- aEvent.NewValue = uno::makeAny( m_aProps.getTitle() );
+ aEvent.OldValue <<= aOldTitle;
+ aEvent.NewValue <<= m_aProps.getTitle();
aChanges.getArray()[ nChanged ] = aEvent;
nChanged++;
diff --git a/ucb/source/ucp/package/pkgcontent.cxx b/ucb/source/ucp/package/pkgcontent.cxx
index 55a161b27b5c..585f01b402cf 100644
--- a/ucb/source/ucp/package/pkgcontent.cxx
+++ b/ucb/source/ucp/package/pkgcontent.cxx
@@ -1125,8 +1125,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( aNewValue != m_aProps.aMediaType )
{
aEvent.PropertyName = rValue.Name;
- aEvent.OldValue = uno::makeAny( m_aProps.aMediaType );
- aEvent.NewValue = uno::makeAny( aNewValue );
+ aEvent.OldValue <<= m_aProps.aMediaType;
+ aEvent.NewValue <<= aNewValue;
m_aProps.aMediaType = aNewValue;
nChanged++;
@@ -1159,8 +1159,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( bNewValue != m_aProps.bCompressed )
{
aEvent.PropertyName = rValue.Name;
- aEvent.OldValue = uno::makeAny( m_aProps.bCompressed );
- aEvent.NewValue = uno::makeAny( bNewValue );
+ aEvent.OldValue <<= m_aProps.bCompressed;
+ aEvent.NewValue <<= bNewValue;
m_aProps.bCompressed = bNewValue;
nChanged++;
@@ -1193,8 +1193,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( bNewValue != m_aProps.bEncrypted )
{
aEvent.PropertyName = rValue.Name;
- aEvent.OldValue = uno::makeAny( m_aProps.bEncrypted );
- aEvent.NewValue = uno::makeAny( bNewValue );
+ aEvent.OldValue <<= m_aProps.bEncrypted;
+ aEvent.NewValue <<= bNewValue;
m_aProps.bEncrypted = bNewValue;
nChanged++;
@@ -1238,9 +1238,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( aNewValue != m_aProps.aEncryptionKey )
{
aEvent.PropertyName = rValue.Name;
- aEvent.OldValue = uno::makeAny(
- m_aProps.aEncryptionKey );
- aEvent.NewValue = uno::makeAny( aNewValue );
+ aEvent.OldValue <<= m_aProps.aEncryptionKey;
+ aEvent.NewValue <<= aNewValue;
m_aProps.aEncryptionKey = aNewValue;
nChanged++;
@@ -1353,8 +1352,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( !aNewTitle.isEmpty() )
{
aEvent.PropertyName = "Title";
- aEvent.OldValue = uno::makeAny( m_aProps.aTitle );
- aEvent.NewValue = uno::makeAny( aNewTitle );
+ aEvent.OldValue <<= m_aProps.aTitle;
+ aEvent.NewValue <<= aNewTitle;
m_aProps.aTitle = aNewTitle;
diff --git a/ucb/source/ucp/tdoc/tdoc_content.cxx b/ucb/source/ucp/tdoc/tdoc_content.cxx
index f480b97069aa..b120960aca72 100644
--- a/ucb/source/ucp/tdoc/tdoc_content.cxx
+++ b/ucb/source/ucp/tdoc/tdoc_content.cxx
@@ -1328,8 +1328,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
if ( !aOldTitle.isEmpty() )
{
aEvent.PropertyName = "Title";
- aEvent.OldValue = uno::makeAny( aOldTitle );
- aEvent.NewValue = uno::makeAny( m_aProps.getTitle() );
+ aEvent.OldValue <<= aOldTitle;
+ aEvent.NewValue <<= m_aProps.getTitle();
aChanges.getArray()[ nChanged ] = aEvent;
nChanged++;
diff --git a/ucb/source/ucp/webdav-neon/webdavcontent.cxx b/ucb/source/ucp/webdav-neon/webdavcontent.cxx
index 5ca16f6d0e30..255a1cd0f850 100644
--- a/ucb/source/ucp/webdav-neon/webdavcontent.cxx
+++ b/ucb/source/ucp/webdav-neon/webdavcontent.cxx
@@ -752,7 +752,7 @@ uno::Any SAL_CALL Content::execute(
// Unreachable
}
- aRet = uno::makeAny( createNewContent( aArg ) );
+ aRet <<= createNewContent( aArg );
}
else if ( aCommand.Name == "addProperty" )
{
@@ -2144,8 +2144,8 @@ uno::Sequence< uno::Any > Content::setPropertyValues(
osl::Guard< osl::Mutex > aGuard( m_aMutex );
aEvent.PropertyName = "Title";
- aEvent.OldValue = uno::makeAny( aOldTitle );
- aEvent.NewValue = uno::makeAny( aNewTitle );
+ aEvent.OldValue <<= aOldTitle;
+ aEvent.NewValue <<= aNewTitle;
m_aEscapedTitle = NeonUri::escapeSegment( aNewTitle );