From 657144ced06a015ae4dc2b2f18c7f9d2cc2c59b8 Mon Sep 17 00:00:00 2001 From: iiPython Date: Sat, 3 Feb 2024 17:32:41 -0600 Subject: [PATCH 1/2] Simple one line fix for global hotkeys --- src/main/main.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/main.ts b/src/main/main.ts index 2ca95d900..b70f75701 100644 --- a/src/main/main.ts +++ b/src/main/main.ts @@ -635,7 +635,7 @@ ipcMain.on( const globalMediaKeysEnabled = store.get('global_media_hotkeys') as boolean; - if (globalMediaKeysEnabled) { + if (globalMediaKeysEnabled !== false) { enableMediaKeys(mainWindow); } }, From 030f13eabade870400474d368309b41964439ebc Mon Sep 17 00:00:00 2001 From: iiPython Date: Sat, 3 Feb 2024 18:33:41 -0600 Subject: [PATCH 2/2] Clean up codebase via default values --- src/main/main.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/main.ts b/src/main/main.ts index b70f75701..189eaf9d0 100644 --- a/src/main/main.ts +++ b/src/main/main.ts @@ -317,9 +317,9 @@ const createWindow = async () => { } }); - const globalMediaKeysEnabled = store.get('global_media_hotkeys') as boolean; + const globalMediaKeysEnabled = store.get('global_media_hotkeys', true) as boolean; - if (globalMediaKeysEnabled !== false) { + if (globalMediaKeysEnabled) { enableMediaKeys(mainWindow); } @@ -633,9 +633,9 @@ ipcMain.on( } } - const globalMediaKeysEnabled = store.get('global_media_hotkeys') as boolean; + const globalMediaKeysEnabled = store.get('global_media_hotkeys', true) as boolean; - if (globalMediaKeysEnabled !== false) { + if (globalMediaKeysEnabled) { enableMediaKeys(mainWindow); } },