mirror of
https://github.com/ValveSoftware/Proton.git
synced 2024-12-28 07:35:50 +03:00
steam-helper: Create list of games to ignore selected locale
First, and only on this list so far is Guild Wars 2 (1284210) CW-Bug-Id: #23824
This commit is contained in:
parent
bb76da532e
commit
ed3c44ecbc
@ -130,6 +130,9 @@ static void setup_steam_registry(void)
|
|||||||
char buf[256];
|
char buf[256];
|
||||||
HKEY key;
|
HKEY key;
|
||||||
LSTATUS status;
|
LSTATUS status;
|
||||||
|
const int system_locale_appids[] = {
|
||||||
|
1284210 /* Guild Wars 2 */
|
||||||
|
};
|
||||||
|
|
||||||
ui_lang = SteamUtils()->GetSteamUILanguage();
|
ui_lang = SteamUtils()->GetSteamUILanguage();
|
||||||
WINE_TRACE("UI language: %s\n", wine_dbgstr_a(ui_lang));
|
WINE_TRACE("UI language: %s\n", wine_dbgstr_a(ui_lang));
|
||||||
@ -156,6 +159,18 @@ static void setup_steam_registry(void)
|
|||||||
languages = SteamApps()->GetAvailableGameLanguages();
|
languages = SteamApps()->GetAvailableGameLanguages();
|
||||||
WINE_TRACE( "Game language %s, available %s\n", wine_dbgstr_a(language), wine_dbgstr_a(languages) );
|
WINE_TRACE( "Game language %s, available %s\n", wine_dbgstr_a(language), wine_dbgstr_a(languages) );
|
||||||
|
|
||||||
|
if (strchr(languages, ',') == NULL) /* If there is a list of languages then respect that */
|
||||||
|
{
|
||||||
|
for (int i = 0; i < (sizeof(system_locale_appids) / sizeof(*system_locale_appids)); i++)
|
||||||
|
{
|
||||||
|
if (system_locale_appids[i] == appid)
|
||||||
|
{
|
||||||
|
WINE_TRACE("Not changing system locale for application %i\n",appid);
|
||||||
|
language = NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!language) locale = NULL;
|
if (!language) locale = NULL;
|
||||||
else if (!strcmp( language, "arabic" )) locale = "ar_001.UTF-8";
|
else if (!strcmp( language, "arabic" )) locale = "ar_001.UTF-8";
|
||||||
else if (!strcmp( language, "bulgarian" )) locale = "bg_BG.UTF-8";
|
else if (!strcmp( language, "bulgarian" )) locale = "bg_BG.UTF-8";
|
||||||
|
Loading…
Reference in New Issue
Block a user