hide songs loaded from AdditionalSongFolders

This commit is contained in:
Chris Danford
2006-04-04 21:52:54 +00:00
parent be3e197485
commit 27c7482556
4 changed files with 13 additions and 4 deletions
+10 -2
View File
@@ -37,8 +37,9 @@
SongManager* SONGMAN = NULL; // global and accessable from anywhere in our program
const RString SONGS_DIR = "Songs/";
const RString COURSES_DIR = "Courses/";
const RString SONGS_DIR = "/Songs/";
const RString ADDITIONAL_SONGS_DIR = "/AdditionalSongs/";
const RString COURSES_DIR = "/Courses/";
static const ThemeMetric<RageColor> EXTRA_COLOR ("SongManager","ExtraColor");
static const ThemeMetric<int> EXTRA_COLOR_METER ("SongManager","ExtraColorMeter");
@@ -103,6 +104,7 @@ void SongManager::InitSongsFromDisk( LoadingWindow *ld )
{
RageTimer tm;
LoadStepManiaSongDir( SONGS_DIR, ld );
LoadStepManiaSongDir( ADDITIONAL_SONGS_DIR, ld );
LOG->Trace( "Found %d songs in %f seconds.", (int)m_pSongs.size(), tm.GetDeltaTime() );
}
@@ -937,6 +939,12 @@ void SongManager::DeleteSteps( Steps *pSteps )
pSong->DeleteSteps( pSteps );
}
bool SongManager::WasLoadedFromAdditionalSongs( const Song *pSong ) const
{
RString sDir = pSong->GetSongDir();
return BeginsWith( sDir, ADDITIONAL_SONGS_DIR );
}
void SongManager::GetAllCourses( vector<Course*> &AddTo, bool bIncludeAutogen )
{
for( unsigned i=0; i<m_pCourses.size(); i++ )