summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorJacek Fraczek <fraczek.jacek@gmail.com>2016-10-05 22:00:51 +0200
committerStephan Bergmann <sbergman@redhat.com>2016-10-10 08:48:30 +0000
commitf004aa99514d385f3ee254bba735f5eaeb7d9ad8 (patch)
treeaacd5792f553b8e9cbf029cc7e0797ed0dd423fe /filter
parent728c7327bd97602a38723553ed044ea4c01d13b2 (diff)
tdf#89307: Removed SvRef::operator T*()
Conditional statements are using SvRef::Is() method. Changed static_cast<T*>(svRef<T>) occurances to svRef.get(). Added operator == and != to SvRef. SbxObject::Execute is using SbxVariableRef internally. SbxObject::FindQualified is using SbxVariableRef internally. Change-Id: I45b553e35d8fca9bf71163e6eefc60802a066395 Reviewed-on: https://gerrit.libreoffice.org/29621 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'filter')
-rw-r--r--filter/source/msfilter/msdffimp.cxx8
-rw-r--r--filter/source/msfilter/svdfppt.cxx4
-rw-r--r--filter/source/msfilter/svxmsbas2.cxx2
3 files changed, 7 insertions, 7 deletions
diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx
index 2ba8dfd20a31..92e887d7e1fd 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -6792,7 +6792,7 @@ bool SvxMSDffManager::ConvertToOle2( SvStream& rStm, sal_uInt32 nReadLen,
if( ERRCODE_NONE == GraphicConverter::Import( rStm, aGraphic ) && aGraphic.GetType() != GraphicType::NONE )
{
const GDIMetaFile& rMtf = aGraphic.GetGDIMetaFile();
- MakeContentStream( rDest, rMtf );
+ MakeContentStream( rDest.get(), rMtf );
bMtfRead = true;
}
// set behind the data
@@ -6805,7 +6805,7 @@ bool SvxMSDffManager::ConvertToOle2( SvStream& rStm, sal_uInt32 nReadLen,
if( !bMtfRead && pMtf )
{
- MakeContentStream( rDest, *pMtf );
+ MakeContentStream( rDest.get(), *pMtf );
return true;
}
@@ -6947,7 +6947,7 @@ css::uno::Reference < css::embed::XEmbeddedObject > SvxMSDffManager::CheckForCo
{
SfxFilterMatcher aMatch( sStarName );
tools::SvRef<SotStorage> xStorage = new SotStorage( false, *xMemStream );
- rSrcStg.CopyTo( xStorage );
+ rSrcStg.CopyTo( xStorage.get() );
xStorage->Commit();
xStorage.Clear();
OUString aType = SfxFilter::GetTypeFromStorage( rSrcStg );
@@ -7146,7 +7146,7 @@ SdrOle2Obj* SvxMSDffManager::CreateSdrOLEFromStorage(
if ( xObjStor.Is() )
{
tools::SvRef<SotStorage> xSrcStor = rSrcStorage->OpenSotStorage( rStorageName, StreamMode::READ );
- xSrcStor->CopyTo( xObjStor );
+ xSrcStor->CopyTo( xObjStor.get() );
if( !xObjStor->GetError() )
xObjStor->Commit();
diff --git a/filter/source/msfilter/svdfppt.cxx b/filter/source/msfilter/svdfppt.cxx
index 01b3366e2fd1..479c374fd665 100644
--- a/filter/source/msfilter/svdfppt.cxx
+++ b/filter/source/msfilter/svdfppt.cxx
@@ -1901,7 +1901,7 @@ SdrObject* SdrPowerPointImport::ImportOLE( long nOLEId,
tools::SvRef<SotStorage> xTarget = SotStorage::OpenOLEStorage( pOe->pShell->GetStorage(), aNm, StreamMode::READWRITE );
if ( xObjStor.Is() && xTarget.Is() )
{
- xObjStor->CopyTo( xTarget );
+ xObjStor->CopyTo( xTarget.get() );
if( !xTarget->GetError() )
xTarget->Commit();
}
@@ -2034,7 +2034,7 @@ void SdrPowerPointImport::SeekOle( SfxObjectShell* pShell, sal_uInt32 nFilterOpt
for ( i = 0; i < aList.size(); i++ ) // copy all entries
{
const SvStorageInfo& rInfo = aList[ i ];
- if ( !xSource->CopyTo( rInfo.GetName(), xMacros, rInfo.GetName() ) )
+ if ( !xSource->CopyTo( rInfo.GetName(), xMacros.get(), rInfo.GetName() ) )
bCopied = false;
}
if ( i && bCopied )
diff --git a/filter/source/msfilter/svxmsbas2.cxx b/filter/source/msfilter/svxmsbas2.cxx
index e9aa27764f91..1ea178aed5a7 100644
--- a/filter/source/msfilter/svxmsbas2.cxx
+++ b/filter/source/msfilter/svxmsbas2.cxx
@@ -47,7 +47,7 @@ ErrCode SvxImportMSVBasic::SaveOrDelMSVBAStorage( bool bSaveInto,
#endif
tools::SvRef<SotStorage> xSrc = SotStorage::OpenOLEStorage( xSrcRoot, aDstStgName, StreamMode::STD_READ );
tools::SvRef<SotStorage> xDst = xRoot->OpenSotStorage( rStorageName, StreamMode::READWRITE | StreamMode::TRUNC );
- xSrc->CopyTo( xDst );
+ xSrc->CopyTo( xDst.get() );
xDst->Commit();
ErrCode nError = xDst->GetError();
if ( nError == ERRCODE_NONE )