Windows compilation fixes
This commit is contained in:
@@ -570,7 +570,9 @@ void SetupColoursAndInitialWindow()
|
|||||||
static int counter = 5; // This part of code is called several times during startup, which closes all windows, so we need to put random hacks here
|
static int counter = 5; // This part of code is called several times during startup, which closes all windows, so we need to put random hacks here
|
||||||
counter--;
|
counter--;
|
||||||
ShowGameOptions();
|
ShowGameOptions();
|
||||||
|
#ifndef WIN32
|
||||||
if (counter == 0) unsetenv("SDL_RESTART_PARAMS");
|
if (counter == 0) unsetenv("SDL_RESTART_PARAMS");
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|||||||
@@ -737,12 +737,14 @@ int openttd_main(int argc, char *argv[])
|
|||||||
_cursor.in_window = true;
|
_cursor.in_window = true;
|
||||||
|
|
||||||
{
|
{
|
||||||
|
#ifndef WIN32
|
||||||
// Configure local font path on Android
|
// Configure local font path on Android
|
||||||
//char curdir[PATH_MAX];
|
//char curdir[PATH_MAX];
|
||||||
//getcwd(curdir, sizeof(curdir));
|
//getcwd(curdir, sizeof(curdir));
|
||||||
//setenv("FONTCONFIG_FONTS", (std::string(curdir) + "/fonts").c_str(), 1);
|
//setenv("FONTCONFIG_FONTS", (std::string(curdir) + "/fonts").c_str(), 1);
|
||||||
setenv("FONTCONFIG_FONTS", "fonts", 1);
|
setenv("FONTCONFIG_FONTS", "fonts", 1);
|
||||||
DEBUG(misc, 1, "Set FONTCONFIG_FONTS to %s", getenv("FONTCONFIG_FONTS"));
|
DEBUG(misc, 1, "Set FONTCONFIG_FONTS to %s", getenv("FONTCONFIG_FONTS"));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
/* enumerate language files */
|
/* enumerate language files */
|
||||||
InitializeLanguagePacks();
|
InitializeLanguagePacks();
|
||||||
|
|||||||
Reference in New Issue
Block a user