write Catalog.xml only after loading songs

get rid of try/catch in SongManager
get rid of try/catch in PrefsManager
This commit is contained in:
Chris Danford
2004-05-25 05:52:57 +00:00
parent 8e654b59ea
commit 962cdfc4f0
6 changed files with 29 additions and 37 deletions
+9 -13
View File
@@ -42,18 +42,6 @@ ProfileManager* PROFILEMAN = NULL; // global and accessable from anywhere in our
ProfileManager::ProfileManager()
{
PROFILEMAN = this;
try
{
FOREACH_PlayerNumber( p )
m_bWasLoadedFromMemoryCard[p] = false;
LoadMachineProfile();
} catch(...) {
PROFILEMAN = NULL;
throw;
}
}
ProfileManager::~ProfileManager()
@@ -61,6 +49,14 @@ ProfileManager::~ProfileManager()
SaveMachineProfile();
}
void ProfileManager::Init()
{
FOREACH_PlayerNumber( p )
m_bWasLoadedFromMemoryCard[p] = false;
LoadMachineProfile();
}
void ProfileManager::GetLocalProfileIDs( vector<CString> &asProfileIDsOut ) const
{
GetDirListing( USER_PROFILES_DIR "*", asProfileIDsOut, true, false );
@@ -76,7 +72,7 @@ void ProfileManager::GetLocalProfileNames( vector<CString> &asNamesOut ) const
CString sProfileID = vsProfileIDs[i];
CString sProfileDir = USER_PROFILES_DIR + sProfileID + "/";
CString sDisplayName = Profile::GetProfileDisplayNameFromDir( sProfileDir );
LOG->Trace(" '%s'", sDisplayName.c_str());
LOG->Trace(" '%s'", sDisplayName.c_str());
asNamesOut.push_back( sDisplayName );
}
}