Bug 1641546 - Make the new WebRTC global sharing indicator a dialog instead of a popup. r=pbz
authorMike Conley <mconley@mozilla.com>
Fri, 05 Jun 2020 14:29:29 +0000
changeset 534157 72a62a455c476a293bafb9a0f1c205b44838c0ab
parent 534156 4746c37be3e6ff7c566f44070eddd66908acfd20
child 534158 2652e1c084a77120435b075939c36026b4811e69
push id37483
push userapavel@mozilla.com
push dateFri, 05 Jun 2020 21:40:11 +0000
treeherdermozilla-central@dadc7312128e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspbz
bugs1641546
milestone79.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1641546 - Make the new WebRTC global sharing indicator a dialog instead of a popup. r=pbz Depends on D77696 Differential Revision: https://phabricator.services.mozilla.com/D77504
browser/modules/webrtcUI.jsm
widget/tests/test_alwaysontop_focus.xhtml
--- a/browser/modules/webrtcUI.jsm
+++ b/browser/modules/webrtcUI.jsm
@@ -712,17 +712,17 @@ var webrtcUI = {
     );
   },
 };
 
 function getGlobalIndicator() {
   if (!webrtcUI.useLegacyGlobalIndicator) {
     const INDICATOR_CHROME_URI =
       "chrome://browser/content/webrtcIndicator.xhtml";
-    let features = "chrome,titlebar=no,alwaysontop,minimizable=yes,popup=yes";
+    let features = "chrome,titlebar=no,alwaysontop,minimizable=yes";
 
     /* Don't use dialog on Gtk as it adds extra border and titlebar to indicator */
     if (!AppConstants.MOZ_WIDGET_GTK) {
       features += ",dialog=yes";
     }
 
     return Services.ww.openWindow(
       null,
--- a/widget/tests/test_alwaysontop_focus.xhtml
+++ b/widget/tests/test_alwaysontop_focus.xhtml
@@ -3,21 +3,27 @@
 <head>
   <meta charset="utf-8" />
   <title>Test that alwaysontop windows do not pull focus when opened.</title>
   <script src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
   <link rel="stylesheet" href="chrome://mochikit/content/tests/SimpleTest/test.css"/>
   <script><![CDATA[
     add_task(async function testAlwaysOnTop() {
       const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-      let topWin = docShell.rootTreeItem.domWindow;
+      let topWin = window.docShell.rootTreeItem.domWindow;
       await SimpleTest.promiseFocus(topWin);
       is(Services.focus.activeWindow, topWin, "Top level window is focused");
 
-      let newWin = Services.ww.openWindow(null, "about:blank", null, "chrome,alwaysontop,width=300,height=300", null);
+      let newWin = Services.ww.openWindow(
+        null,
+        "about:blank",
+        null,
+        "chrome,alwaysontop,width=300,height=300",
+        null
+      );
       await new Promise(resolve => {
         newWin.addEventListener("load", resolve, { once: true });
       });
 
       // Wait one tick of the event loop to give the window a chance to focus.
       await new Promise(resolve => { SimpleTest.executeSoon(resolve); });
 
       is(Services.focus.activeWindow, topWin, "Top level window is still focused");