Bug 908277 - Prevent permission UI errors when PopupNotifications is not available. r=dolske

This commit is contained in:
Drew Willcoxon 2013-11-11 15:36:54 -08:00
parent f9bfd407e3
commit 0e08490bca

View File

@ -2030,6 +2030,13 @@ ContentPermissionPrompt.prototype = {
}
}
var browser = this._getBrowserForRequest(request);
var chromeWin = browser.ownerDocument.defaultView;
if (!chromeWin.PopupNotifications)
// Ignore requests from browsers hosted in windows that don't support
// PopupNotifications.
return;
// Show the prompt.
switch (request.type) {
case "geolocation":