fix blacklist image filenames being case-sensitive
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
#define NOTES_LOADER_H
|
||||
|
||||
#include "song.h"
|
||||
#include "RageUtil.h"
|
||||
#include <set>
|
||||
|
||||
typedef int DanceNote;
|
||||
@@ -25,11 +26,11 @@ class NotesLoader {
|
||||
protected:
|
||||
virtual void GetApplicableFiles( CString sPath, CStringArray &out )=0;
|
||||
|
||||
set<CString> BlacklistedImages;
|
||||
set<istring> BlacklistedImages;
|
||||
|
||||
public:
|
||||
virtual ~NotesLoader() { }
|
||||
const set<CString> &GetBlacklistedImages() const { return BlacklistedImages; }
|
||||
const set<istring> &GetBlacklistedImages() const { return BlacklistedImages; }
|
||||
static void GetMainAndSubTitlesFromFullTitle( const CString sFullTitle, CString &sMainTitleOut, CString &sSubTitleOut );
|
||||
virtual bool LoadFromDir( CString sPath, Song &out ) = 0;
|
||||
bool Loadable( CString sPath );
|
||||
|
||||
@@ -484,7 +484,7 @@ bool DWILoader::LoadFromDWIFile( CString sPath, Song &out )
|
||||
|
||||
pos = endpos + 1;
|
||||
|
||||
BlacklistedImages.insert( sub );
|
||||
BlacklistedImages.insert( sub.c_str() );
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -336,7 +336,7 @@ NotesLoader *Song::MakeLoader( CString sDir ) const
|
||||
|
||||
/* Hack: This should be a parameter to TidyUpData, but I don't want to
|
||||
* pull in <set> into Song.h, which is heavily used. */
|
||||
static set<CString> BlacklistedImages;
|
||||
static set<istring> BlacklistedImages;
|
||||
|
||||
bool Song::LoadWithoutCache( CString sDir )
|
||||
{
|
||||
@@ -686,7 +686,7 @@ void Song::TidyUpData()
|
||||
for( i=0; i<arrayImages.size(); i++ ) // foreach image
|
||||
{
|
||||
// ignore DWI "-char" graphics
|
||||
if( BlacklistedImages.find( arrayImages[i] ) != BlacklistedImages.end() )
|
||||
if( BlacklistedImages.find( arrayImages[i].c_str() ) != BlacklistedImages.end() )
|
||||
continue; // skip
|
||||
|
||||
// Skip any image that we've already classified
|
||||
|
||||
Reference in New Issue
Block a user