Use map<> in IniFile.

This has a side-effect: written INIs are sorted by key and name.
Unintentional, but not necessarily a bad thing ...
This commit is contained in:
Glenn Maynard
2002-10-24 23:08:18 +00:00
parent dc43775b83
commit 0a73e01186
4 changed files with 74 additions and 127 deletions
+6 -5
View File
@@ -259,13 +259,14 @@ void SongManager::ReadStatisticsFromDisk()
// load song statistics
IniFile::key* pKey = ini.GetKey( "Statistics" );
if( pKey )
IniFile::const_iterator Key = ini.GetKey( "Statistics" );
if( Key != ini.end() )
{
for( int i=0; i<pKey->names.GetSize(); i++ )
for( IniFile::key::const_iterator i = Key->second.begin();
i != Key->second.end(); ++i )
{
CString name = pKey->names[i];
CString value = pKey->values[i];
CString name = i->first;
CString value = i->second;
// Each value has the format "SongName::StepsName=TimesPlayed::TopGrade::TopScore::MaxCombo".
char szSongDir[256];