From 8333c3412438cf4bd9d89389bf5a14cb0635d062 Mon Sep 17 00:00:00 2001 From: "mr. m" <91018726+mr-cheffy@users.noreply.github.com> Date: Sat, 4 Apr 2026 20:50:25 +0200 Subject: [PATCH] gh-13077: Fixed ctrl+W closing window when splitting tabs (gh-13083) --- src/browser/base/content/browser-commands-js.patch | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/browser/base/content/browser-commands-js.patch b/src/browser/base/content/browser-commands-js.patch index fa9a0af70..87a12716c 100644 --- a/src/browser/base/content/browser-commands-js.patch +++ b/src/browser/base/content/browser-commands-js.patch @@ -1,5 +1,5 @@ diff --git a/browser/base/content/browser-commands.js b/browser/base/content/browser-commands.js -index 75ddd82c18979571f377dec94fe1883f1349cc16..58ae4d88f7f0b37187cb61fcaf4cf84a9af7991f 100644 +index 75ddd82c18979571f377dec94fe1883f1349cc16..129d78214db53fc8dbd17d23b4a5a042ec297a41 100644 --- a/browser/base/content/browser-commands.js +++ b/browser/base/content/browser-commands.js @@ -14,6 +14,10 @@ var BrowserCommands = { @@ -24,11 +24,14 @@ index 75ddd82c18979571f377dec94fe1883f1349cc16..58ae4d88f7f0b37187cb61fcaf4cf84a // A notification intended to be useful for modular peformance tracking // starting as close as is reasonably possible to the time when the user // expressed the intent to open a new tab. Since there are a lot of -@@ -399,6 +407,11 @@ var BrowserCommands = { +@@ -399,6 +407,14 @@ var BrowserCommands = { return; } + if (gBrowser.selectedTab.hasAttribute("zen-empty-tab")) { ++ if (gBrowser.selectedTab.hasAttribute("split-view")) { ++ return; ++ } + gZenWorkspaces.handleTabCloseWindow(); + return; + } @@ -36,7 +39,7 @@ index 75ddd82c18979571f377dec94fe1883f1349cc16..58ae4d88f7f0b37187cb61fcaf4cf84a // Keyboard shortcuts that would close a tab that is pinned select the first // unpinned tab instead. if ( -@@ -406,8 +419,8 @@ var BrowserCommands = { +@@ -406,8 +422,8 @@ var BrowserCommands = { (event.ctrlKey || event.metaKey || event.altKey) && gBrowser.selectedTab.pinned ) {