From f91e85c53e1f8bc3700feb20250cf4c1fd22455a Mon Sep 17 00:00:00 2001 From: AJ Kelly Date: Thu, 6 Oct 2011 14:58:00 -0500 Subject: [PATCH] some small changes to background/disc graphic finding logic. --- src/Song.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/Song.cpp b/src/Song.cpp index fa3f0b475e..84f45bf124 100644 --- a/src/Song.cpp +++ b/src/Song.cpp @@ -613,8 +613,9 @@ void Song::TidyUpData( bool fromCache, bool duringCache ) // find an image with "bg" or "background" in the file name vector arrayPossibleBGs; - GetImageDirListing( m_sSongDir + "*bg*", arrayPossibleBGs ); GetImageDirListing( m_sSongDir + "*background*", arrayPossibleBGs ); + // don't match e.g. "subgroup", "hobgoblin", etc. + GetImageDirListing( m_sSongDir + "*bg", arrayPossibleBGs ); if( !arrayPossibleBGs.empty() ) m_sBackgroundFile = arrayPossibleBGs[0]; } @@ -644,8 +645,8 @@ void Song::TidyUpData( bool fromCache, bool duringCache ) { // a rectangular graphic, not to be confused with CDImage above. vector arrayPossibleDiscImages; - GetImageDirListing( m_sSongDir + "* Disc", arrayPossibleDiscImages ); - GetImageDirListing( m_sSongDir + "* Title", arrayPossibleDiscImages ); + GetImageDirListing( m_sSongDir + "* disc", arrayPossibleDiscImages ); + GetImageDirListing( m_sSongDir + "* title", arrayPossibleDiscImages ); if( !arrayPossibleDiscImages.empty() ) m_sDiscFile = arrayPossibleDiscImages[0]; }