Bug 746178 - Use the metaKey to close the window on OSX r=marcoz
authorAthena <athena@fastmail.fm>
Wed, 02 Jul 2014 07:43:00 +0200
changeset 192171 2d229d0aa401aab7114d19d2eb061c6ed31ccda3
parent 192170 73db6acaf49f853cc7438ae88eb28b6a1818bf3a
child 192172 3de3f4f8a97087143741557a75a0506d19a441e8
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewersmarcoz
bugs746178
milestone33.0a1
Bug 746178 - Use the metaKey to close the window on OSX r=marcoz Reenable the test for Mac
accessible/tests/mochitest/events/test_focus_browserui.xul
--- a/accessible/tests/mochitest/events/test_focus_browserui.xul
+++ b/accessible/tests/mochitest/events/test_focus_browserui.xul
@@ -91,27 +91,30 @@
                                browserWindow()));
 
       // open new url, focus moves to new document
       gQueue.push(new loadURI(gButtonDocURI));
 
       // back one page in history, moves moves on input of tab document
       gQueue.push(new goBack());
 
-if (!MAC) {
       // open new tab, focus moves to urlbar
-      gQueue.push(new synthKey(tabDocument, "t", { ctrlKey: true, window: browserWindow() },
+      var synthKeyArgs;
+      if (MAC) {
+        synthKeyArgs = { metaKey: true, window: browserWindow() };
+      } else {
+        synthKeyArgs = { ctrlKey: true, window: browserWindow() };
+      }
+
+      gQueue.push(new synthKey(tabDocument, "t", synthKeyArgs,
                                new focusChecker(urlbarInput)));
 
       // close open tab, focus goes on input of tab document
-      gQueue.push(new synthKey(tabDocument, "w", { ctrlKey: true, window: browserWindow() },
+      gQueue.push(new synthKey(tabDocument, "w", synthKeyArgs,
                                new focusChecker(inputInDocument)));
-} else {
-      todo(false, "Reenable on Mac after fixing bug 746178!");
-}
 
       gQueue.onFinish = function()
       {
         closeBrowserWindow();
       }
       gQueue.invoke();
     }