Add edit management screen

This commit is contained in:
Chris Danford
2005-11-30 22:42:28 +00:00
parent 8cb7360ab6
commit cbe4ef50b5
9 changed files with 423 additions and 3 deletions
+35
View File
@@ -865,6 +865,41 @@ void SongManager::SetPreferences()
}
}
void SongManager::GetStepsLoadedFromProfile( vector<Steps*> &AddTo, ProfileSlot slot )
{
const vector<Song*> &vSongs = SONGMAN->GetAllSongs();
FOREACH_CONST( Song*, vSongs, song )
{
(*song)->GetStepsLoadedFromProfile( slot, AddTo );
}
}
Song *SongManager::GetSongFromSteps( Steps *pSteps )
{
const vector<Song*> &vSongs = SONGMAN->GetAllSongs();
FOREACH_CONST( Song*, vSongs, song )
{
vector<Steps*> vSteps;
(*song)->GetSteps( vSteps );
FOREACH_CONST( Steps*, vSteps, steps )
{
if( *steps == pSteps )
{
return *song;
}
}
}
ASSERT(0);
return NULL;
}
void SongManager::DeleteSteps( Steps *pSteps )
{
Song *pSong = GetSongFromSteps( pSteps );
pSong->DeleteSteps( pSteps );
}
void SongManager::GetAllCourses( vector<Course*> &AddTo, bool bIncludeAutogen )
{
for( unsigned i=0; i<m_pCourses.size(); i++ )