Fixed broken window save/restore

merge-requests/55/head
Tag 2021-01-10 10:43:44 -08:00
rodzic f29a620133
commit c25b1a7be9
1 zmienionych plików z 9 dodań i 2 usunięć

Wyświetl plik

@ -82,6 +82,7 @@ var g_isShowing = false;
nw.Window.get().on("loaded", function ()
{
s_title = document.title.substr(0, 16).trim();
g_isShowing = false;
if (typeof localStorage.screenSettings == "undefined")
{
@ -100,8 +101,14 @@ nw.Window.get().on("loaded", function ()
g_isShowing = s_screenSettings[s_title].showing;
nw.Window.get().zoomLevel = s_zoomLevel = s_screenSettings[s_title].zoomLevel;
if (g_isShowing || document.title == "GridTracker") this.show();
else this.hide();
if (g_isShowing || s_title.indexOf("GridTracker") == 0 )
{
this.show();
}
else
{
this.hide();
}
g_initialScreenCount = nw.Screen.screens.length;
setWindowInfo();