summaryrefslogtreecommitdiff
path: root/idl/source/prj/database.cxx
diff options
context:
space:
mode:
authorJoseph Powers <jpowers27@cox.net>2010-12-28 18:02:06 -0800
committerJoseph Powers <jpowers27@cox.net>2010-12-31 06:57:20 -0800
commit2e2bcb6cb9310e8c995f0b03ce1bf990dd03292f (patch)
treedb87a38d49e719d915f46e5ecd098229d5c524cb /idl/source/prj/database.cxx
parentcdd425de05e1a6098a732115014b258e2a69a076 (diff)
Remove DECLARE_LIST( StringList, String * )
Diffstat (limited to 'idl/source/prj/database.cxx')
-rw-r--r--idl/source/prj/database.cxx22
1 files changed, 8 insertions, 14 deletions
diff --git a/idl/source/prj/database.cxx b/idl/source/prj/database.cxx
index ba4aa19aeb5e..d2c44f7b5821 100644
--- a/idl/source/prj/database.cxx
+++ b/idl/source/prj/database.cxx
@@ -74,12 +74,10 @@ SvIdlDataBase::SvIdlDataBase( const SvCommand& rCmd )
*************************************************************************/
SvIdlDataBase::~SvIdlDataBase()
{
- String * pStr = aIdFileList.First();
- while( pStr )
- {
- delete pStr;
- pStr = aIdFileList.Next();
- }
+ for ( size_t i = 0, n = aIdFileList.size(); i < n; ++i )
+ delete aIdFileList[ i ];
+ aIdFileList.clear();
+
delete pIdTable;
}
@@ -320,15 +318,11 @@ BOOL SvIdlDataBase::ReadIdFile( const String & rFileName )
DirEntry aFullName( rFileName );
aFullName.Find( GetPath() );
- String * pIdFile = aIdFileList.First();
- while( pIdFile )
- {
- if( *pIdFile == rFileName )
- return TRUE; // schon eingelesen
- pIdFile = aIdFileList.Next();
- }
+ for ( size_t i = 0, n = aIdFileList.size(); i < n; ++i )
+ if ( *aIdFileList[ i ] == rFileName )
+ return TRUE;
- aIdFileList.Insert( new String( rFileName ), LIST_APPEND );
+ aIdFileList.push_back( new String( rFileName ) );
SvTokenStream aTokStm( aFullName.GetFull() );
if( aTokStm.GetStream().GetError() == SVSTREAM_OK )