From 1c29206e079e0b94ceeeadbbfd09006b22063e96 Mon Sep 17 00:00:00 2001 From: "mr. m" <91018726+mr-cheffy@users.noreply.github.com> Date: Tue, 26 May 2026 23:14:36 +0200 Subject: [PATCH] gh-12284: Sync upstream Firefox to version `151.0.2` (gh-13875) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This PR syncs the upstream Firefox to version 151.0.2. * ⚠️ Some patches did not apply cleanly. Please review them carefully. @mr-cheffy please review and merge this PR. --------- Signed-off-by: mr. m <91018726+mr-cheffy@users.noreply.github.com> --- README.md | 4 ++-- build/firefox-cache/l10n-last-commit-hash | 2 +- src/browser/modules/URILoadingHelper-sys-mjs.patch | 12 ++++++------ src/zen/sessionstore/ZenWindowSync.sys.mjs | 9 ++++++++- surfer.json | 6 +++--- 5 files changed, 20 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 5e46f4dc9..cb51a0f61 100644 --- a/README.md +++ b/README.md @@ -34,8 +34,8 @@ Zen is a firefox-based browser with the aim of pushing your productivity to a ne ### Firefox Versions -- [`Release`](https://zen-browser.app/download) - Is currently built using Firefox version `151.0.1`! 🚀 -- [`Twilight`](https://zen-browser.app/download?twilight) - Is currently built using Firefox version `RC 151.0.1`! +- [`Release`](https://zen-browser.app/download) - Is currently built using Firefox version `151.0.2`! 🚀 +- [`Twilight`](https://zen-browser.app/download?twilight) - Is currently built using Firefox version `RC 151.0.2`! ### Contributing diff --git a/build/firefox-cache/l10n-last-commit-hash b/build/firefox-cache/l10n-last-commit-hash index f6c433445..7bcc95dc3 100644 --- a/build/firefox-cache/l10n-last-commit-hash +++ b/build/firefox-cache/l10n-last-commit-hash @@ -1 +1 @@ -10b4efc5a79c2ab80de3b22771b1d36b9b225920 \ No newline at end of file +05272df13c2e4f435b4e0a706715f302b09ef829 \ No newline at end of file diff --git a/src/browser/modules/URILoadingHelper-sys-mjs.patch b/src/browser/modules/URILoadingHelper-sys-mjs.patch index a804e232a..82ac3592b 100644 --- a/src/browser/modules/URILoadingHelper-sys-mjs.patch +++ b/src/browser/modules/URILoadingHelper-sys-mjs.patch @@ -1,8 +1,8 @@ diff --git a/browser/modules/URILoadingHelper.sys.mjs b/browser/modules/URILoadingHelper.sys.mjs -index ed6b9fda700b2b4b35836a77a4da953377a72f4b..22acedcf1006f994ec8b6bf8991b4202e12a6f39 100644 +index bd2e54e914b171df9b8bcc7dcbc2388e9641f6c6..8b3cb6542bea3fb89e47adc93cb13f94447450e2 100644 --- a/browser/modules/URILoadingHelper.sys.mjs +++ b/browser/modules/URILoadingHelper.sys.mjs -@@ -224,6 +224,7 @@ function openInWindow(url, params, sourceWindow) { +@@ -228,6 +228,7 @@ function openInWindow(url, params, sourceWindow) { features, sa ); @@ -10,7 +10,7 @@ index ed6b9fda700b2b4b35836a77a4da953377a72f4b..22acedcf1006f994ec8b6bf8991b4202 } function openInCurrentTab(targetBrowser, url, uriObj, params) { -@@ -541,7 +542,7 @@ export const URILoadingHelper = { +@@ -545,7 +546,7 @@ export const URILoadingHelper = { // page. If a load request bounces off for the currently selected tab, // we'll open a new tab instead. let tab = w.gBrowser.getTabForBrowser(targetBrowser); @@ -19,7 +19,7 @@ index ed6b9fda700b2b4b35836a77a4da953377a72f4b..22acedcf1006f994ec8b6bf8991b4202 where = "tab"; targetBrowser = null; } else if ( -@@ -974,7 +975,7 @@ export const URILoadingHelper = { +@@ -978,7 +979,7 @@ export const URILoadingHelper = { ignoreQueryString || replaceQueryString, ignoreFragmentWhenComparing ); @@ -28,8 +28,8 @@ index ed6b9fda700b2b4b35836a77a4da953377a72f4b..22acedcf1006f994ec8b6bf8991b4202 for (let i = 0; i < browsers.length; i++) { let browser = browsers[i]; let browserCompare = cleanURL( -@@ -1026,7 +1027,7 @@ export const URILoadingHelper = { - aSplitView.replaceTab(tabToReplace, tabToMove); +@@ -1034,7 +1035,7 @@ export const URILoadingHelper = { + } aSplitView.ownerGlobal.focus(); } else { - aWindow.gBrowser.tabContainer.selectedIndex = i; diff --git a/src/zen/sessionstore/ZenWindowSync.sys.mjs b/src/zen/sessionstore/ZenWindowSync.sys.mjs index ede60adeb..12993d74b 100644 --- a/src/zen/sessionstore/ZenWindowSync.sys.mjs +++ b/src/zen/sessionstore/ZenWindowSync.sys.mjs @@ -1534,7 +1534,14 @@ class nsZenWindowSync { window.removeEventListener(eventName, this); } delete window.gZenWindowSync; - this.#moveAllActiveTabsToOtherWindowsForClose(window); + const { promise, resolve } = Promise.withResolvers(); + this.#docShellSwitchPromise = promise; + try { + this.#moveAllActiveTabsToOtherWindowsForClose(window); + } catch (e) { + console.error(`Error moving active tabs to other windows on close:`, e); + } + resolve(); } on_WindowCloseAndBrowserFlushed(aBrowsers) { diff --git a/surfer.json b/surfer.json index ef7606370..a53e9df9a 100644 --- a/surfer.json +++ b/surfer.json @@ -5,8 +5,8 @@ "binaryName": "zen", "version": { "product": "firefox", - "version": "151.0.1", - "candidate": "151.0.1", + "version": "151.0.2", + "candidate": "151.0.2", "candidateBuild": 1 }, "buildOptions": { @@ -20,7 +20,7 @@ "brandShortName": "Zen", "brandFullName": "Zen Browser", "release": { - "displayVersion": "1.20b", + "displayVersion": "1.20.1b", "github": { "repo": "zen-browser/desktop" },