Oops - looks like the unused function I deleted was used (and I
am nearly certain it compiled when I tried :( ). git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@9972 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
5caee0a9fc
commit
a294b36ced
@ -110,6 +110,27 @@ void MusicManager::loadMusicInformation()
|
||||
} // loadMusicInformation
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
void MusicManager::loadMusicFromOneDir(const std::string& dir)
|
||||
{
|
||||
std::set<std::string> files;
|
||||
file_manager->listFiles(files, dir, /*is_full_path*/ true,
|
||||
/*make_full_path*/ true);
|
||||
for(std::set<std::string>::iterator i = files.begin(); i != files.end(); ++i)
|
||||
{
|
||||
if(StringUtils::getExtension(*i)!="music") continue;
|
||||
try
|
||||
{
|
||||
m_all_music[StringUtils::getBasename(*i)] = new MusicInformation(*i);
|
||||
}
|
||||
catch (std::exception& e)
|
||||
{
|
||||
(void)e; // avoid compiler warning
|
||||
continue;
|
||||
}
|
||||
} // for i
|
||||
} // loadMusicFromOneDir
|
||||
|
||||
//-----------------------------------------------------------------------------//-----------------------------------------------------------------------------
|
||||
void MusicManager::addMusicToTracks()
|
||||
{
|
||||
for(std::map<std::string,MusicInformation*>::iterator i=m_all_music.begin();
|
||||
|
@ -76,6 +76,7 @@ public:
|
||||
*/
|
||||
MusicInformation *getMusicInformation(const std::string& filename);
|
||||
|
||||
void loadMusicFromOneDir(const std::string& dir);
|
||||
void addMusicToTracks();
|
||||
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user