зеркало из https://github.com/mozilla/pjs.git
Bug 750159 - Sometimes we get 'browser is null' errors in onLocationChange so remove the need for the browser r=mbrubeck
This commit is contained in:
Родитель
1872cc9077
Коммит
7f82739553
|
@ -2208,15 +2208,10 @@ Tab.prototype = {
|
|||
if (contentWin != contentWin.top)
|
||||
return;
|
||||
|
||||
let browser = BrowserApp.getBrowserForWindow(contentWin);
|
||||
let uri = browser.currentURI.spec;
|
||||
let documentURI = "";
|
||||
let contentType = "";
|
||||
let uri = aLocationURI.spec;
|
||||
let documentURI = contentWin.document.documentURIObject.spec;
|
||||
let contentType = contentWin.document.contentType;
|
||||
let sameDocument = (aFlags & Ci.nsIWebProgressListener.LOCATION_CHANGE_SAME_DOCUMENT) != 0;
|
||||
if (browser.contentDocument) {
|
||||
documentURI = browser.contentDocument.documentURIObject.spec;
|
||||
contentType = browser.contentDocument.contentType;
|
||||
}
|
||||
|
||||
// Reset state of click-to-play plugin notifications.
|
||||
this.clickToPlayPluginDoorhangerShown = false;
|
||||
|
|
Загрузка…
Ссылка в новой задаче