From 04b8375105889eccd9ca2b2bf3125ff4ab22a634 Mon Sep 17 00:00:00 2001 From: "J.T. Sage" Date: Tue, 20 Aug 2024 17:00:06 -0400 Subject: [PATCH] Fix dirty folder status flag (was not updating in UI), bump to 5.0.0-RC1 --- .vscode/settings.json | 1 + lib/modAssist_func_lib.js | 1 + modAssist_main.js | 1 + package.json | 2 +- renderer/renderJS/main_ui_lib.js | 2 ++ 5 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 8d0121c0..dbc7a4f0 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -67,6 +67,7 @@ "DDSD", "DEDI", "deepl", + "deepmerge", "DESCVERSION", "digestate", "docdash", diff --git a/lib/modAssist_func_lib.js b/lib/modAssist_func_lib.js index 87197f09..5ab78b43 100644 --- a/lib/modAssist_func_lib.js +++ b/lib/modAssist_func_lib.js @@ -127,6 +127,7 @@ const general = { toggleFolderDirty : (newValue = true) => { serveIPC.isFoldersDirty = newValue + serveIPC.windowLib.sendToValidWindow('main', 'status:all') }, initUpdater : () => { diff --git a/modAssist_main.js b/modAssist_main.js index fbf08ea8..ab9a6c98 100644 --- a/modAssist_main.js +++ b/modAssist_main.js @@ -881,6 +881,7 @@ ipcMain.on('main:runUpdateInstall', () => { ipcMain.handle('state:all', () => { return { botStatus : serveIPC.modCollect.botDetails, dangerDebug : serveIPC.isDebugDanger, + foldersDirty : serveIPC.isFoldersDirty, gameRunning : serveIPC.isGameRunning, gameRunningEnabled : serveIPC.isGamePolling, pinMini : serveIPC.windowLib.isAlwaysOnTop('mini'), diff --git a/package.json b/package.json index 1dc2b193..930b4d95 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "fsg-mod-assistant", - "version": "4.9.84", + "version": "4.9.91", "description": "FSG Farm Sim Mod Assistant", "main": "modAssist_main.js", "homepage": "https://github.com/FSGModding/FSG_Mod_Assistant#readme", diff --git a/renderer/renderJS/main_ui_lib.js b/renderer/renderJS/main_ui_lib.js index 72fe1200..dce3927c 100644 --- a/renderer/renderJS/main_ui_lib.js +++ b/renderer/renderJS/main_ui_lib.js @@ -207,8 +207,10 @@ class StateManager { window.main_IPC.updateState().then((status) => { MA.byId('debug_danger_bubble').clsShow(status.dangerDebug) MA.byId('topBar-update').clsShow(status.updateReady) + this.flag.folderDirty = status.foldersDirty this.flag.gameRunning = status.gameRunning this.flag.launchEnable = status.gameRunningEnabled + MA.byId('dirty_folders').clsShow(this.flag.folderDirty) MA.byId('gameRunningBubble') .clsShow(this.flag.launchEnable) .clsOrGate(this.flag.gameRunning, 'text-success', 'text-danger')