Bug 1209689 - Only show about:tabcrashed for the selected tab. r=felipe

This commit is contained in:
Mike Conley 2015-10-28 15:30:43 -04:00
parent 23dd537fcf
commit b0d82a9706

View File

@ -4427,13 +4427,19 @@
let uri = browser.currentURI;
let icon = browser.mIconURL;
this.updateBrowserRemotenessByURL(browser, "about:tabcrashed");
browser.setAttribute("crashedPageTitle", title);
browser.docShell.displayLoadError(Cr.NS_ERROR_CONTENT_CRASHED, uri, null);
browser.removeAttribute("crashedPageTitle");
let tab = this.getTabForBrowser(browser);
tab.setAttribute("crashed", true);
if (this.selectedBrowser == browser) {
this.updateBrowserRemotenessByURL(browser, "about:tabcrashed");
browser.setAttribute("crashedPageTitle", title);
browser.docShell.displayLoadError(Cr.NS_ERROR_CONTENT_CRASHED, uri, null);
browser.removeAttribute("crashedPageTitle");
tab.setAttribute("crashed", true);
} else {
this.updateBrowserRemoteness(browser, false);
SessionStore.reviveCrashedTab(tab);
}
tab.removeAttribute("soundplaying");
this.setIcon(tab, icon);
]]>