Loading browser/actors/BrowserTabChild.sys.mjs +0 −34 Original line number Diff line number Diff line Loading @@ -3,12 +3,6 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ const lazy = {}; ChromeUtils.defineESModuleGetters(lazy, { E10SUtils: "resource://gre/modules/E10SUtils.sys.mjs", }); export class BrowserTabChild extends JSWindowActorChild { constructor() { super(); Loading @@ -19,34 +13,6 @@ export class BrowserTabChild extends JSWindowActorChild { let docShell = context.docShell; switch (message.name) { // XXX(nika): Should we try to call this in the parent process instead? case "Browser:Reload": /* First, we'll try to use the session history object to reload so * that framesets are handled properly. If we're in a special * window (such as view-source) that has no session history, fall * back on using the web navigation's reload method. */ let webNav = docShell.QueryInterface(Ci.nsIWebNavigation); try { if (webNav.sessionHistory) { webNav = webNav.sessionHistory; } } catch (e) {} let reloadFlags = message.data.flags; if (message.data.handlingUserInput) { reloadFlags |= Ci.nsIWebNavigation.LOAD_FLAGS_USER_ACTIVATION; } try { lazy.E10SUtils.wrapHandlingUserInput( this.document.defaultView, message.data.handlingUserInput, () => webNav.reload(reloadFlags) ); } catch (e) {} break; case "ForceEncodingDetection": docShell.forceEncodingDetection(); break; Loading browser/base/content/browser.js +17 −12 Original line number Diff line number Diff line Loading @@ -3488,17 +3488,29 @@ function BrowserReloadWithFlags(reloadFlags) { gIdentityHandler.hidePopup(); gPermissionPanel.hidePopup(); let handlingUserInput = document.hasValidTransientUserGestureActivation; if (document.hasValidTransientUserGestureActivation) { reloadFlags |= Ci.nsIWebNavigation.LOAD_FLAGS_USER_ACTIVATION; } for (let tab of unchangedRemoteness) { if (tab.linkedPanel) { sendReloadMessage(tab); const { browsingContext } = tab.linkedBrowser; const { sessionHistory } = browsingContext; if (sessionHistory) { sessionHistory.reload(reloadFlags); } else { browsingContext.reload(reloadFlags); } } else { // Shift to fully loaded browser and make // sure load handler is instantiated. tab.addEventListener("SSTabRestoring", () => sendReloadMessage(tab), { tab.addEventListener( "SSTabRestoring", () => tab.linkedBrowser.browsingContext.reload(reloadFlags), { once: true, }); } ); gBrowser._insertBrowser(tab); } } Loading @@ -3510,13 +3522,6 @@ function BrowserReloadWithFlags(reloadFlags) { }); } function sendReloadMessage(tab) { tab.linkedBrowser.sendMessageToActor( "Browser:Reload", { flags: reloadFlags, handlingUserInput }, "BrowserTab" ); } } // TODO: can we pull getPEMString in from pippki.js instead of Loading docshell/shistory/nsISHistory.idl +1 −2 Original line number Diff line number Diff line Loading @@ -268,8 +268,7 @@ interface nsISHistory: nsISupports [noscript, notxpcom] void RemoveFrameEntries(in nsISHEntry aEntry); [noscript] void Reload(in unsigned long aReloadFlags); void reload(in unsigned long aReloadFlags); [notxpcom] void EnsureCorrectEntryAtCurrIndex(in nsISHEntry aEntry); Loading Loading
browser/actors/BrowserTabChild.sys.mjs +0 −34 Original line number Diff line number Diff line Loading @@ -3,12 +3,6 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ const lazy = {}; ChromeUtils.defineESModuleGetters(lazy, { E10SUtils: "resource://gre/modules/E10SUtils.sys.mjs", }); export class BrowserTabChild extends JSWindowActorChild { constructor() { super(); Loading @@ -19,34 +13,6 @@ export class BrowserTabChild extends JSWindowActorChild { let docShell = context.docShell; switch (message.name) { // XXX(nika): Should we try to call this in the parent process instead? case "Browser:Reload": /* First, we'll try to use the session history object to reload so * that framesets are handled properly. If we're in a special * window (such as view-source) that has no session history, fall * back on using the web navigation's reload method. */ let webNav = docShell.QueryInterface(Ci.nsIWebNavigation); try { if (webNav.sessionHistory) { webNav = webNav.sessionHistory; } } catch (e) {} let reloadFlags = message.data.flags; if (message.data.handlingUserInput) { reloadFlags |= Ci.nsIWebNavigation.LOAD_FLAGS_USER_ACTIVATION; } try { lazy.E10SUtils.wrapHandlingUserInput( this.document.defaultView, message.data.handlingUserInput, () => webNav.reload(reloadFlags) ); } catch (e) {} break; case "ForceEncodingDetection": docShell.forceEncodingDetection(); break; Loading
browser/base/content/browser.js +17 −12 Original line number Diff line number Diff line Loading @@ -3488,17 +3488,29 @@ function BrowserReloadWithFlags(reloadFlags) { gIdentityHandler.hidePopup(); gPermissionPanel.hidePopup(); let handlingUserInput = document.hasValidTransientUserGestureActivation; if (document.hasValidTransientUserGestureActivation) { reloadFlags |= Ci.nsIWebNavigation.LOAD_FLAGS_USER_ACTIVATION; } for (let tab of unchangedRemoteness) { if (tab.linkedPanel) { sendReloadMessage(tab); const { browsingContext } = tab.linkedBrowser; const { sessionHistory } = browsingContext; if (sessionHistory) { sessionHistory.reload(reloadFlags); } else { browsingContext.reload(reloadFlags); } } else { // Shift to fully loaded browser and make // sure load handler is instantiated. tab.addEventListener("SSTabRestoring", () => sendReloadMessage(tab), { tab.addEventListener( "SSTabRestoring", () => tab.linkedBrowser.browsingContext.reload(reloadFlags), { once: true, }); } ); gBrowser._insertBrowser(tab); } } Loading @@ -3510,13 +3522,6 @@ function BrowserReloadWithFlags(reloadFlags) { }); } function sendReloadMessage(tab) { tab.linkedBrowser.sendMessageToActor( "Browser:Reload", { flags: reloadFlags, handlingUserInput }, "BrowserTab" ); } } // TODO: can we pull getPEMString in from pippki.js instead of Loading
docshell/shistory/nsISHistory.idl +1 −2 Original line number Diff line number Diff line Loading @@ -268,8 +268,7 @@ interface nsISHistory: nsISupports [noscript, notxpcom] void RemoveFrameEntries(in nsISHEntry aEntry); [noscript] void Reload(in unsigned long aReloadFlags); void reload(in unsigned long aReloadFlags); [notxpcom] void EnsureCorrectEntryAtCurrIndex(in nsISHEntry aEntry); Loading