From f9dc4e8ccdc2a582cefff9e5389995ab73e7a420 Mon Sep 17 00:00:00 2001 From: FranklinDM Date: Wed, 22 May 2019 19:24:30 +0800 Subject: Issue #971 - Fix browser.link.open_newwindow functionality in Pale Moon --- application/palemoon/base/content/browser.js | 1 - 1 file changed, 1 deletion(-) (limited to 'application/palemoon/base/content/browser.js') diff --git a/application/palemoon/base/content/browser.js b/application/palemoon/base/content/browser.js index 3f8a584bf..cc362d23f 100644 --- a/application/palemoon/base/content/browser.js +++ b/application/palemoon/base/content/browser.js @@ -4481,7 +4481,6 @@ nsBrowserAccess.prototype = { } let loadInBackground = gPrefService.getBoolPref("browser.tabs.loadDivertedInBackground"); - let referrer = aOpener ? makeURI(aOpener.location.href) : null; let tab = win.gBrowser.loadOneTab(aURI ? aURI.spec : "about:blank", { triggeringPrincipal: triggeringPrincipal, -- cgit v1.2.3 From 10318170bca9a08b1f3716e245aba5432d60aa2a Mon Sep 17 00:00:00 2001 From: FranklinDM Date: Thu, 23 May 2019 13:39:01 +0800 Subject: Issue #1104 - Pass an opener to loadOneTab in the openURI function --- application/palemoon/base/content/browser.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'application/palemoon/base/content/browser.js') diff --git a/application/palemoon/base/content/browser.js b/application/palemoon/base/content/browser.js index cc362d23f..16b7c0019 100644 --- a/application/palemoon/base/content/browser.js +++ b/application/palemoon/base/content/browser.js @@ -4481,13 +4481,15 @@ nsBrowserAccess.prototype = { } let loadInBackground = gPrefService.getBoolPref("browser.tabs.loadDivertedInBackground"); + let openerWindow = (aContext & Ci.nsIBrowserDOMWindow.OPEN_NO_OPENER) ? null : aOpener; let tab = win.gBrowser.loadOneTab(aURI ? aURI.spec : "about:blank", { triggeringPrincipal: triggeringPrincipal, referrerURI: referrer, referrerPolicy: referrerPolicy, fromExternal: isExternal, - inBackground: loadInBackground}); + inBackground: loadInBackground, + opener: openerWindow }); let browser = win.gBrowser.getBrowserForTab(tab); if (gPrefService.getBoolPref("browser.tabs.noWindowActivationOnExternal")) { -- cgit v1.2.3