From 58a32075ca4f457f570af75aef368dd6c389aca7 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 3 May 2016 08:39:03 +0200 Subject: use Any constructor instead of temporaries Change-Id: Iffb82a2cee1a28d89eeea2b905aaa14086ee475a --- editeng/source/misc/svxacorr.cxx | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'editeng') diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx index 2a261aebd244..de4254289544 100644 --- a/editeng/source/misc/svxacorr.cxx +++ b/editeng/source/misc/svxacorr.cxx @@ -2049,9 +2049,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 = @@ -2344,14 +2342,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 (...) { @@ -2421,9 +2417,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(); -- cgit