summaryrefslogtreecommitdiff
path: root/rsc/source/parser/rscdb.cxx
diff options
context:
space:
mode:
authorJoseph Powers <jpowers27@cox.net>2011-01-24 19:37:57 -0800
committerJoseph Powers <jpowers27@cox.net>2011-01-24 19:37:57 -0800
commit5772e5eca11eff0b5fdf7415d57590da04bfd257 (patch)
treeb15c53f5a41e8856b6c293193c3c5f8127225f9f /rsc/source/parser/rscdb.cxx
parenteb841ee60977024af788f8c5821d8c5558faad4b (diff)
Remove DECLARE_LIST( RscSysList, RscSysEntry * )
Diffstat (limited to 'rsc/source/parser/rscdb.cxx')
-rw-r--r--rsc/source/parser/rscdb.cxx31
1 files changed, 14 insertions, 17 deletions
diff --git a/rsc/source/parser/rscdb.cxx b/rsc/source/parser/rscdb.cxx
index bb31fefdf446..03e8874eadad 100644
--- a/rsc/source/parser/rscdb.cxx
+++ b/rsc/source/parser/rscdb.cxx
@@ -224,8 +224,6 @@ void Pre_dtorTree( RscTop * pRscTop ){
}
RscTypCont :: ~RscTypCont(){
- RscSysEntry * pSysEntry;
-
// Alle Unterbaeume loeschen
aVersion.pClass->Destroy( aVersion );
rtl_freeMemory( aVersion.pData );
@@ -256,17 +254,16 @@ RscTypCont :: ~RscTypCont(){
delete aBaseLst[ i ];
aBaseLst.clear();
- while( NULL != (pSysEntry = aSysLst.Remove()) ){
- delete pSysEntry;
- };
+ for ( size_t i = 0, n = aSysLst.size(); i < n; ++i )
+ delete aSysLst[ i ];
+ aSysLst.clear();
}
void RscTypCont::ClearSysNames()
{
- RscSysEntry * pSysEntry;
- while( NULL != (pSysEntry = aSysLst.Remove()) ){
- delete pSysEntry;
- };
+ for ( size_t i = 0, n = aSysLst.size(); i < n; ++i )
+ delete aSysLst[ i ];
+ aSysLst.clear();
}
//=======================================================================
@@ -375,17 +372,17 @@ sal_uInt32 RscTypCont :: PutSysName( sal_uInt32 nRscTyp, char * pFileName,
RscSysEntry * pSysEntry;
BOOL bId1 = FALSE;
- pSysEntry = aSysLst.First();
- while( pSysEntry )
+ for ( size_t i = 0, n = aSysLst.size(); i < n; ++i )
{
+ pSysEntry = aSysLst[ i ];
if( pSysEntry->nKey == 1 )
bId1 = TRUE;
if( !strcmp( pSysEntry->aFileName.GetBuffer(), pFileName ) )
- if( pSysEntry->nRscTyp == nRscTyp
- && pSysEntry->nTyp == nConst
- && pSysEntry->nRefId == nId )
+ if( pSysEntry->nRscTyp == nRscTyp
+ && pSysEntry->nTyp == nConst
+ && pSysEntry->nRefId == nId
+ )
break;
- pSysEntry = aSysLst.Next();
}
if ( !pSysEntry || (bFirst && !bId1) )
@@ -399,10 +396,10 @@ sal_uInt32 RscTypCont :: PutSysName( sal_uInt32 nRscTyp, char * pFileName,
if( bFirst && !bId1 )
{
pSysEntry->nKey = 1;
- aSysLst.Insert( pSysEntry, (ULONG)0 );
+ aSysLst.insert( aSysLst.begin(), pSysEntry );
}
else
- aSysLst.Insert( pSysEntry, LIST_APPEND );
+ aSysLst.push_back( pSysEntry );
}
return pSysEntry->nKey;