Bug 863515 - Switch usages of content.opener to gBrowser.selectedBrowser.hasContentOpener. r=felipe.

--HG--
extra : rebase_source : c5db34ab7faf3bad74224e24d0faf09431a503f3
This commit is contained in:
Mike Conley 2015-05-08 12:16:12 -04:00
Родитель 623fec3e84
Коммит f5c3435326
1 изменённых файлов: 3 добавлений и 5 удалений

Просмотреть файл

@ -2389,9 +2389,8 @@ function URLBarSetURI(aURI) {
// Replace initial page URIs with an empty string
// only if there's no opener (bug 370555).
// Bug 863515 - Make content.opener checks work in electrolysis.
if (gInitialPages.indexOf(uri.spec) != -1)
value = !gMultiProcessBrowser && content.opener ? uri.spec : "";
value = gBrowser.selectedBrowser.hasContentOpener ? uri.spec : "";
else
value = losslessDecodeURI(uri);
@ -4158,7 +4157,7 @@ var XULBrowserWindow = {
// Do not update urlbar if there was a subframe navigation
if (aWebProgress.isTopLevel) {
if ((location == "about:blank" && (gMultiProcessBrowser || !content.opener)) ||
if ((location == "about:blank" && !gBrowser.selectedBrowser.hasContentOpener) ||
location == "") { // Second condition is for new tabs, otherwise
// reload function is enabled until tab is refreshed.
this.reloadCommand.setAttribute("disabled", "true");
@ -6533,8 +6532,7 @@ function isTabEmpty(aTab) {
if (!isBlankPageURL(browser.currentURI.spec))
return false;
// Bug 863515 - Make content.opener checks work in electrolysis.
if (!gMultiProcessBrowser && browser.contentWindow.opener)
if (browser.hasContentOpener)
return false;
if (browser.canGoForward || browser.canGoBack)