Bug 1597793 - Check if a window is not a popup in ext-utils's onLocationChange. r=snorp

Differential Revision: https://phabricator.services.mozilla.com/D60986

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Agi Sferro 2020-01-25 07:27:10 +00:00
Родитель ab9177e525
Коммит 16bd2d03b1
1 изменённых файлов: 7 добавлений и 0 удалений

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

@ -89,6 +89,13 @@ class BrowserProgressListener {
}
onLocationChange(webProgress, request, locationURI, flags) {
const window = this.browser.ownerGlobal;
// GeckoView windows can become popups at any moment, so we need to check
// here
if (!windowTracker.isBrowserWindow(window)) {
return;
}
this.delegate("onLocationChange", webProgress, request, locationURI, flags);
}
onStateChange(webProgress, request, stateFlags, status) {