summaryrefslogtreecommitdiffstats
path: root/embedding/components
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@wolfbeast.com>2020-03-18 21:15:10 +0100
committerwolfbeast <mcwerewolf@wolfbeast.com>2020-04-14 13:10:23 +0200
commit3aae828871ac19c4b510a7213a6401b4d751f5ef (patch)
treef6965b51be8ad25f80b8f31d99c2745dda2c769f /embedding/components
parente7514afc7c13516cdd56e8ffba4399c7c1c974ba (diff)
downloadUXP-3aae828871ac19c4b510a7213a6401b4d751f5ef.tar
UXP-3aae828871ac19c4b510a7213a6401b4d751f5ef.tar.gz
UXP-3aae828871ac19c4b510a7213a6401b4d751f5ef.tar.lz
UXP-3aae828871ac19c4b510a7213a6401b4d751f5ef.tar.xz
UXP-3aae828871ac19c4b510a7213a6401b4d751f5ef.zip
[DOM] Make sure to exit fullscreen mode if popups are opened or focused.
Diffstat (limited to 'embedding/components')
-rw-r--r--embedding/components/windowwatcher/nsWindowWatcher.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/embedding/components/windowwatcher/nsWindowWatcher.cpp b/embedding/components/windowwatcher/nsWindowWatcher.cpp
index 3732ea66d..fa23e285b 100644
--- a/embedding/components/windowwatcher/nsWindowWatcher.cpp
+++ b/embedding/components/windowwatcher/nsWindowWatcher.cpp
@@ -1297,6 +1297,12 @@ nsWindowWatcher::OpenWindowInternal(mozIDOMWindowProxy* aParent,
}
}
+ // If a website opens a popup exit DOM fullscreen
+ if (windowIsNew && aCalledFromJS && !hasChromeParent && !isCallerChrome &&
+ parentWindow) {
+ nsIDocument::AsyncExitFullscreen(parentWindow->GetDoc());
+ }
+
if (aForceNoOpener && windowIsNew) {
NS_RELEASE(*aResult);
}