Bug 931445 part 4 - Ensure pointer is moved into the window for APZ mouseevent test. r=kats
authorXidorn Quan <me@upsuper.org>
Fri, 27 May 2016 17:13:05 +1000
changeset 340289 daf83079577fa7b8407c18164c6cf490290c8304
parent 340288 ab3d00f4e239cc38d8c692d2854689af11537eda
child 340290 0fa7d5fb96afee035e4fe0cfa27692c9c7d344a2
push id1183
push userraliiev@mozilla.com
push dateMon, 05 Sep 2016 20:01:49 +0000
treeherdermozilla-release@3148731bed45 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskats
bugs931445
milestone49.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 931445 part 4 - Ensure pointer is moved into the window for APZ mouseevent test. r=kats MozReview-Commit-ID: HiRf1qHjSL9
gfx/layers/apz/test/mochitest/helper_drag_click.html
--- a/gfx/layers/apz/test/mochitest/helper_drag_click.html
+++ b/gfx/layers/apz/test/mochitest/helper_drag_click.html
@@ -7,16 +7,18 @@
   <script type="application/javascript" src="apz_test_native_event_utils.js"></script>
   <script type="application/javascript" src="apz_test_utils.js"></script>
   <script type="application/javascript" src="/tests/SimpleTest/paint_listener.js"></script>
   <script type="application/javascript">
 
 function* test(testDriver) {
   document.addEventListener('click', clicked, false);
 
+  // Ensure the pointer is inside the window
+  yield synthesizeNativeMouseEvent(document.getElementById('b'), 5, 5, nativeMouseMoveEventMsg(), testDriver);
   // mouse down, move it around, and release it near where it went down. this
   // should generate a click at the release point
   yield synthesizeNativeMouseEvent(document.getElementById('b'), 5, 5, nativeMouseDownEventMsg(), testDriver);
   yield synthesizeNativeMouseEvent(document.getElementById('b'), 100, 100, nativeMouseMoveEventMsg(), testDriver);
   yield synthesizeNativeMouseEvent(document.getElementById('b'), 10, 10, nativeMouseMoveEventMsg(), testDriver);
   yield synthesizeNativeMouseEvent(document.getElementById('b'), 8, 8, nativeMouseUpEventMsg(), testDriver);
   dump("Finished synthesizing click with a drag in the middle\n");
 }