From f9f3252b33724c6bf995a9603eeb847e12a0b2bf Mon Sep 17 00:00:00 2001 From: Robert Kossessa Date: Fri, 1 Mar 2024 21:08:44 +0100 Subject: [PATCH] DEL: Remove zoom prevention electron-toolkit takes care of this --- src/main/index.ts | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/src/main/index.ts b/src/main/index.ts index b454f3c..6e61c65 100644 --- a/src/main/index.ts +++ b/src/main/index.ts @@ -272,24 +272,3 @@ app.on('window-all-closed', () => { // In this file you can include the rest of your app"s specific main process // code. You can also put them in separate files and require them here. - -// Disable pinch zoom -app.commandLine.appendSwitch('disable-pinch') - -// Disable zoom shortcuts -const ZOOM_IN_SHORTCUTS = ['CmdOrCtrl+numadd', 'CmdOrCtrl+Plus'] -const ZOOM_OUT_SHORTCUTS = ['CmdOrCtrl+numsub', 'CmdOrCtrl+-'] -const ZOOM_RESET_SHORTCUTS = ['CmdOrCtrl+num0', 'CmdOrCtrl+0'] - -app.on('browser-window-focus', () => { - globalShortcut.registerAll( - [...ZOOM_IN_SHORTCUTS, ...ZOOM_OUT_SHORTCUTS, ...ZOOM_RESET_SHORTCUTS], - () => { - // https://www.youtube.com/watch?v=8An2SxNFvmU - } - ) -}) - -app.on('browser-window-blur', () => { - globalShortcut.unregisterAll() -})