Bug 1186325 - Send ack for mousemove message after detecting the event. r=adw
authorNihanth Subramanya <nhnt11@gmail.com>
Thu, 30 Jul 2015 12:16:48 -0700
changeset 287585 4062c2452aad2ccdbf8c82f8dea1939f76a55ae7
parent 287584 397afd7d1e6bd7e6510502af3fe921244a863b5e
child 287586 a78d4180daf51279ab16e1d9789b695c20dbf27a
push id5067
push userraliiev@mozilla.com
push dateMon, 21 Sep 2015 14:04:52 +0000
treeherdermozilla-beta@14221ffe5b2f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersadw
bugs1186325
milestone42.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 1186325 - Send ack for mousemove message after detecting the event. r=adw
browser/base/content/test/general/contentSearchUI.js
--- a/browser/base/content/test/general/contentSearchUI.js
+++ b/browser/base/content/test/general/contentSearchUI.js
@@ -91,18 +91,21 @@ let messageHandlers = {
                      ...gController._oneOffButtons,
                      content.document.getElementById("contentSearchSettingsButton")];
       row = allElts[itemIndex];
     }
     let event = {
       type: "mousemove",
       clickcount: 0,
     }
+    row.addEventListener("mousemove", function handler() {
+      row.removeEventListener("mousemove", handler);
+      ack("mousemove"); 
+    });
     content.synthesizeMouseAtCenter(row, event);
-    ack("mousemove");
   },
 
   click: function (arg) {
     let eltIdx = typeof(arg) == "object" ? arg.eltIdx : arg;
     let row;
     if (eltIdx == -1) {
       row = gController._table.firstChild;
     }