Use cmake to determine which string func we need.

On a side note, better to default to linux names when possible.
This commit is contained in:
Jason Felds
2015-10-07 19:00:16 -04:00
parent dca80f91ae
commit d9a3c9cf97
9 changed files with 33 additions and 21 deletions
+6 -6
View File
@@ -183,7 +183,7 @@ static void GameSel( int &sel, bool ToSel, const ConfOption *pConfOption )
sel = 0;
for(unsigned i = 0; i < choices.size(); ++i)
if( !stricmp(choices[i], sCurGameName) )
if( !strcasecmp(choices[i], sCurGameName) )
sel = i;
} else {
vector<const Game*> aGames;
@@ -218,12 +218,12 @@ static void Language( int &sel, bool ToSel, const ConfOption *pConfOption )
{
sel = -1;
for( unsigned i=0; sel == -1 && i < vs.size(); ++i )
if( !stricmp(vs[i], THEME->GetCurLanguage()) )
if( !strcasecmp(vs[i], THEME->GetCurLanguage()) )
sel = i;
// If the current language doesn't exist, we'll show BASE_LANGUAGE, so select that.
for( unsigned i=0; sel == -1 && i < vs.size(); ++i )
if( !stricmp(vs[i], SpecialFiles::BASE_LANGUAGE) )
if( !strcasecmp(vs[i], SpecialFiles::BASE_LANGUAGE) )
sel = i;
if( sel == -1 )
@@ -272,7 +272,7 @@ static void RequestedTheme( int &sel, bool ToSel, const ConfOption *pConfOption
{
sel = 0;
for( unsigned i=1; i<vsThemeNames.size(); i++ )
if( !stricmp(vsThemeNames[i], PREFSMAN->m_sTheme.Get()) )
if( !strcasecmp(vsThemeNames[i], PREFSMAN->m_sTheme.Get()) )
sel = i;
}
else
@@ -298,7 +298,7 @@ static void Announcer( int &sel, bool ToSel, const ConfOption *pConfOption )
{
sel = 0;
for( unsigned i=1; i<choices.size(); i++ )
if( !stricmp(choices[i], ANNOUNCER->GetCurAnnouncerName()) )
if( !strcasecmp(choices[i], ANNOUNCER->GetCurAnnouncerName()) )
sel = i;
}
else
@@ -325,7 +325,7 @@ static void DefaultNoteSkin( int &sel, bool ToSel, const ConfOption *pConfOption
po.FromString( PREFSMAN->m_sDefaultModifiers );
sel = 0;
for( unsigned i=0; i < choices.size(); i++ )
if( !stricmp(choices[i], po.m_sNoteSkin) )
if( !strcasecmp(choices[i], po.m_sNoteSkin) )
sel = i;
}
else