Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/gui/splashscreen/splashscreen.js
var g_SplashScreenFile = "gui/splashscreen/splashscreen.txt"; | |||||
function init(data) | function init(data) | ||||
{ | { | ||||
Engine.GetGUIObjectByName("mainText").caption = Engine.TranslateLines(Engine.ReadFile("gui/splashscreen/" + data.page + ".txt")); | Engine.GetGUIObjectByName("mainText").caption = Engine.TranslateLines(Engine.ReadFile(g_SplashScreenFile)); | ||||
Engine.GetGUIObjectByName("displaySplashScreen").checked = Engine.ConfigDB_GetValue("user", "gui.splashscreen.enable") === "true"; | Engine.GetGUIObjectByName("displaySplashScreen").checked = Engine.ConfigDB_GetValue("user", "gui.splashscreen.enable") === "true"; | ||||
} | } | ||||
function closePage() | |||||
{ | |||||
saveSettingAndWriteToUserConfig("gui.splashscreen.enable", String(Engine.GetGUIObjectByName("displaySplashScreen").checked)); | |||||
saveSettingAndWriteToUserConfig("gui.splashscreen.version", Engine.GetFileMTime(g_SplashScreenFile)); | |||||
Engine.PopGuiPage(); | |||||
} |
Wildfire Games · Phabricator