mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-02 10:00:54 +00:00
Bug 1583665 - Fixed AddonManager.jsm fullscreen check to only cancel installation for DOM fullscreen. r=johannh
Differential Revision: https://phabricator.services.mozilla.com/D47933 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
5aaa18113b
commit
53a3c77cec
@ -543,7 +543,7 @@ var FullScreen = {
|
||||
// fullscreen window is refocused.
|
||||
window.addEventListener("activate", this);
|
||||
|
||||
// Addon installation should be cancelled when entering fullscreen for security and usability reasons.
|
||||
// Addon installation should be cancelled when entering DOM fullscreen for security and usability reasons.
|
||||
// Installation prompts in fullscreen can trick the user into installing unwanted addons.
|
||||
// In fullscreen the notification box does not have a clear visual association with its parent anymore.
|
||||
if (gXPInstallObserver.removeAllNotifications(aBrowser)) {
|
||||
|
@ -2300,10 +2300,15 @@ var AddonManagerInternal = {
|
||||
}
|
||||
|
||||
try {
|
||||
if (topBrowser.ownerGlobal.fullScreen) {
|
||||
// Addon installation and the resulting notifications should be blocked in fullscreen for security and usability reasons.
|
||||
// Installation prompts in fullscreen can trick the user into installing unwanted addons.
|
||||
// In fullscreen the notification box does not have a clear visual association with its parent anymore.
|
||||
// Use fullscreenElement to check for DOM fullscreen, while still allowing
|
||||
// macOS fullscreen, which still has a browser chrome.
|
||||
if (topBrowser.ownerDocument.fullscreenElement) {
|
||||
// Addon installation and the resulting notifications should be
|
||||
// blocked in DOM fullscreen for security and usability reasons.
|
||||
// Installation prompts in fullscreen can trick the user into
|
||||
// installing unwanted addons.
|
||||
// In fullscreen the notification box does not have a clear
|
||||
// visual association with its parent anymore.
|
||||
aInstall.cancel();
|
||||
|
||||
this.installNotifyObservers(
|
||||
|
Loading…
Reference in New Issue
Block a user