diff options
author | Noel Grandin <noel@peralex.com> | 2016-05-03 08:39:03 +0200 |
---|---|---|
committer | Ashod Nakashian <ashod.nakashian@collabora.co.uk> | 2016-07-20 01:26:04 -0400 |
commit | a0e8e05008e143ee5e3bbc281d1c253c7e5ed136 (patch) | |
tree | eaf5f70a067fd48704addd9f2b582624a2fb44ae /editeng | |
parent | 9c7cae1561cfe16226b1f16dce59f08a38da3ce0 (diff) |
use Any constructor instead of temporaries
(cherry picked from commit 58a32075ca4f457f570af75aef368dd6c389aca7)
Change-Id: Iffb82a2cee1a28d89eeea2b905aaa14086ee475a
Diffstat (limited to 'editeng')
-rw-r--r-- | editeng/source/misc/svxacorr.cxx | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx index 078833856486..2ee3fc4a06e6 100644 --- a/editeng/source/misc/svxacorr.cxx +++ b/editeng/source/misc/svxacorr.cxx @@ -2045,9 +2045,7 @@ void SvxAutoCorrectLanguageLists::SaveExceptList_Imp( xStrm->SetSize( 0 ); xStrm->SetBufferSize( 8192 ); OUString aMime( "text/xml" ); - uno::Any aAny; - aAny <<= aMime; - xStrm->SetProperty( "MediaType", aAny ); + xStrm->SetProperty( "MediaType", Any(aMime) ); uno::Reference< uno::XComponentContext > xContext = @@ -2340,14 +2338,12 @@ void SvxAutoCorrectLanguageLists::MakeUserStorage_Impl() sal_Int32 nSlashPos = sMain.lastIndexOf(cSlash); sMain = sMain.copy(0, nSlashPos); ::ucbhelper::Content aNewContent( sMain, uno::Reference< XCommandEnvironment >(), comphelper::getProcessComponentContext() ); - Any aAny; TransferInfo aInfo; aInfo.NameClash = NameClash::OVERWRITE; aInfo.NewTitle = aDest.GetName(); aInfo.SourceURL = aSource.GetMainURL( INetURLObject::DECODE_TO_IURI ); aInfo.MoveData = false; - aAny <<= aInfo; - aNewContent.executeCommand( "transfer", aAny); + aNewContent.executeCommand( "transfer", Any(aInfo)); } catch (...) { @@ -2417,9 +2413,7 @@ bool SvxAutoCorrectLanguageLists::MakeBlocklist_Imp( SotStorage& rStg ) refList->SetBufferSize( 8192 ); OUString aPropName( "MediaType" ); OUString aMime( "text/xml" ); - uno::Any aAny; - aAny <<= aMime; - refList->SetProperty( aPropName, aAny ); + refList->SetProperty( aPropName, Any(aMime) ); uno::Reference< uno::XComponentContext > xContext = comphelper::getProcessComponentContext(); |