From 70c3facebca43766f2e9f8b41a62230431d37b03 Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Tue, 28 Feb 2006 23:04:24 +0000 Subject: [PATCH] don't use istring here --- stepmania/src/NotesLoader.h | 5 ++--- stepmania/src/NotesLoaderDWI.cpp | 3 ++- stepmania/src/Song.cpp | 6 ++++-- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/stepmania/src/NotesLoader.h b/stepmania/src/NotesLoader.h index 9f7d8b6c73..92004b0ddc 100644 --- a/stepmania/src/NotesLoader.h +++ b/stepmania/src/NotesLoader.h @@ -3,7 +3,6 @@ #ifndef NOTES_LOADER_H #define NOTES_LOADER_H -#include "RageUtil.h" #include class Song; @@ -13,11 +12,11 @@ class NotesLoader protected: virtual void GetApplicableFiles( const RString &sPath, vector &out )=0; - set BlacklistedImages; + set BlacklistedImages; public: virtual ~NotesLoader() { } - const set &GetBlacklistedImages() const { return BlacklistedImages; } + const set &GetBlacklistedImages() const { return BlacklistedImages; } static void GetMainAndSubTitlesFromFullTitle( const RString &sFullTitle, RString &sMainTitleOut, RString &sSubTitleOut ); virtual bool LoadFromDir( const RString &sPath, Song &out ) = 0; virtual void TidyUpData( Song &song, bool cache ) { } diff --git a/stepmania/src/NotesLoaderDWI.cpp b/stepmania/src/NotesLoaderDWI.cpp index 13db465f25..3b1a97464b 100644 --- a/stepmania/src/NotesLoaderDWI.cpp +++ b/stepmania/src/NotesLoaderDWI.cpp @@ -525,7 +525,8 @@ bool DWILoader::LoadFromDWIFile( const RString &sPath, Song &out ) pos = endpos + 1; - BlacklistedImages.insert( sub.c_str() ); + sub.ToLower(); + BlacklistedImages.insert( sub ); } } else diff --git a/stepmania/src/Song.cpp b/stepmania/src/Song.cpp index 3a02f7c7f6..37c4aefa63 100644 --- a/stepmania/src/Song.cpp +++ b/stepmania/src/Song.cpp @@ -192,7 +192,7 @@ NotesLoader *Song::MakeLoader( RString sDir ) const /* Hack: This should be a parameter to TidyUpData, but I don't want to * pull in into Song.h, which is heavily used. */ -static set BlacklistedImages; +static set BlacklistedImages; /* * If PREFSMAN->m_bFastLoad is true, always load from cache if possible. Don't read @@ -641,7 +641,9 @@ void Song::TidyUpData() break; /* done */ // ignore DWI "-char" graphics - if( BlacklistedImages.find( arrayImages[i].c_str() ) != BlacklistedImages.end() ) + RString sLower = arrayImages[i]; + sLower.ToLower(); + if( BlacklistedImages.find(sLower) != BlacklistedImages.end() ) continue; // skip // Skip any image that we've already classified