Kaydet (Commit) 3a27dcd0 authored tarafından Noel Grandin's avatar Noel Grandin Kaydeden (comit) Michael Stahl

Convert SV_DECL_PTRARR_DEL(SvxMSDffBLIPInfos) to boost::ptr_vector

Change-Id: I6cd5793b1ba2a29cbedce7fe5a040651e1664a11
üst e19a2e50
...@@ -43,6 +43,7 @@ ...@@ -43,6 +43,7 @@
#include <filter/msfilter/msfilterdllapi.h> #include <filter/msfilter/msfilterdllapi.h>
#include <sot/storage.hxx> #include <sot/storage.hxx>
#include <vector> #include <vector>
#include <boost/ptr_container/ptr_vector.hpp>
class Graphic; class Graphic;
class SvStream; class SvStream;
...@@ -177,8 +178,6 @@ public: ...@@ -177,8 +178,6 @@ public:
#define COL_DEFAULT RGB_COLORDATA( 0xFA, 0xFB, 0xFC ) #define COL_DEFAULT RGB_COLORDATA( 0xFA, 0xFB, 0xFC )
typedef SvxMSDffBLIPInfo* SvxMSDffBLIPInfo_Ptr;
typedef SvxMSDffShapeInfo* SvxMSDffShapeInfo_Ptr; typedef SvxMSDffShapeInfo* SvxMSDffShapeInfo_Ptr;
typedef ::std::map< sal_Int32, SdrObject* > SvxMSDffShapeIdContainer; typedef ::std::map< sal_Int32, SdrObject* > SvxMSDffShapeIdContainer;
...@@ -186,7 +185,7 @@ typedef ::std::map< sal_Int32, SdrObject* > SvxMSDffShapeIdContainer; ...@@ -186,7 +185,7 @@ typedef ::std::map< sal_Int32, SdrObject* > SvxMSDffShapeIdContainer;
#define SVEXT_PERSIST_STREAM "\002OlePres000" #define SVEXT_PERSIST_STREAM "\002OlePres000"
// nach der Reihenfolge des Auftretens sortiert werden: // nach der Reihenfolge des Auftretens sortiert werden:
SV_DECL_PTRARR_DEL(SvxMSDffBLIPInfos, SvxMSDffBLIPInfo_Ptr, 16) typedef boost::ptr_vector<SvxMSDffBLIPInfo> SvxMSDffBLIPInfos;
class SvxMSDffShapeOrders : public std::vector<SvxMSDffShapeOrder*> class SvxMSDffShapeOrders : public std::vector<SvxMSDffShapeOrder*>
{ {
......
...@@ -5718,8 +5718,6 @@ void SvxMSDffManager::RemoveFromShapeOrder( SdrObject* pObject ) const ...@@ -5718,8 +5718,6 @@ void SvxMSDffManager::RemoveFromShapeOrder( SdrObject* pObject ) const
// Hilfs Deklarationen // Hilfs Deklarationen
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
SV_IMPL_PTRARR( SvxMSDffBLIPInfos, SvxMSDffBLIPInfo_Ptr );
SV_IMPL_OP_PTRARR_SORT( SvxMSDffShapeInfos, SvxMSDffShapeInfo_Ptr ); SV_IMPL_OP_PTRARR_SORT( SvxMSDffShapeInfos, SvxMSDffShapeInfo_Ptr );
SV_IMPL_OP_PTRARR_SORT( SvxMSDffShapeTxBxSort, SvxMSDffShapeOrder* ); SV_IMPL_OP_PTRARR_SORT( SvxMSDffShapeTxBxSort, SvxMSDffShapeOrder* );
...@@ -6105,8 +6103,7 @@ void SvxMSDffManager::GetDrawingGroupContainerData( SvStream& rSt, sal_uLong nLe ...@@ -6105,8 +6103,7 @@ void SvxMSDffManager::GetDrawingGroupContainerData( SvStream& rSt, sal_uLong nLe
nBLIPCount++; nBLIPCount++;
// Jetzt die Infos fuer spaetere Zugriffe speichern // Jetzt die Infos fuer spaetere Zugriffe speichern
pBLIPInfos->Insert( new SvxMSDffBLIPInfo( nInst, nBLIPPos, nBLIPLen ), pBLIPInfos->push_back( new SvxMSDffBLIPInfo( nInst, nBLIPPos, nBLIPLen ) );
pBLIPInfos->Count() );
} }
} }
rSt.SeekRel( nLength ); rSt.SeekRel( nLength );
...@@ -6446,7 +6443,7 @@ sal_Bool SvxMSDffManager::GetBLIP( sal_uLong nIdx_, Graphic& rData, Rectangle* p ...@@ -6446,7 +6443,7 @@ sal_Bool SvxMSDffManager::GetBLIP( sal_uLong nIdx_, Graphic& rData, Rectangle* p
if ( !bOk ) if ( !bOk )
{ {
sal_uInt16 nIdx = sal_uInt16( nIdx_ ); sal_uInt16 nIdx = sal_uInt16( nIdx_ );
if( !nIdx || (pBLIPInfos->Count() < nIdx) ) return sal_False; if( !nIdx || (pBLIPInfos->size() < nIdx) ) return sal_False;
// eventuell alte(s) Errorflag(s) loeschen // eventuell alte(s) Errorflag(s) loeschen
if( rStCtrl.GetError() ) if( rStCtrl.GetError() )
...@@ -6460,7 +6457,7 @@ sal_Bool SvxMSDffManager::GetBLIP( sal_uLong nIdx_, Graphic& rData, Rectangle* p ...@@ -6460,7 +6457,7 @@ sal_Bool SvxMSDffManager::GetBLIP( sal_uLong nIdx_, Graphic& rData, Rectangle* p
sal_uLong nOldPosData = pStData ? pStData->Tell() : nOldPosCtrl; sal_uLong nOldPosData = pStData ? pStData->Tell() : nOldPosCtrl;
// passende Info-Struct aus unserem Pointer Array nehmen // passende Info-Struct aus unserem Pointer Array nehmen
SvxMSDffBLIPInfo& rInfo = *(*pBLIPInfos)[ nIdx-1 ]; SvxMSDffBLIPInfo& rInfo = (*pBLIPInfos)[ nIdx-1 ];
// das BLIP Atom im Daten Stream anspringen // das BLIP Atom im Daten Stream anspringen
pStData->Seek( rInfo.nFilePos ); pStData->Seek( rInfo.nFilePos );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment