From 9efee50d405b8ca990d30114fb6ec6a57e2e92f1 Mon Sep 17 00:00:00 2001 From: _ov4 Date: Thu, 22 Oct 2026 02:02:27 +0000 Subject: feat(bundle): open independent native windows with CtrlCmd+Shift+N macOS only activates a running app, so a second document needs another window in the same process. Each window label gets its own Runner, which is stopped when its window is destroyed or the app exits, and the capability now covers every window. Co-Authored-By: Claude Opus 5.5 --- bundle/src/main.js | 2 ++ 1 file changed, 2 insertions(+) (limited to 'bundle/src/main.js') diff --git a/bundle/src/main.js b/bundle/src/main.js index 991ef06..4d06998 100644 --- a/bundle/src/main.js +++ b/bundle/src/main.js @@ -139,6 +139,8 @@ async function action(callback) { // CtrlCmd is Cmd on macOS and Ctrl elsewhere, matching Monaco's own keybindings. const shortcuts = [ [KeyMod.CtrlCmd | KeyCode.KeyN, () => action(newFile)], + // Each window is an independent native OS window, even while this one runs. + [KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KeyN, () => invoke('new_window').catch(report)], [KeyMod.CtrlCmd | KeyCode.KeyO, () => action(openFile)], [KeyMod.CtrlCmd | KeyCode.KeyS, () => action(saveFile)], [KeyMod.CtrlCmd | KeyCode.KeyF, () => { editor.focus(); editor.getAction('actions.find').run(); }] -- cgit v1.3.1-4-g156e