Bug 1299199 - Part 2: Remove 'sendPointerEvent' from mochitest_support_external.js. f=btseng, r=smaug
authorHo-Pang Hsu <hopang.hsu@gmail.com>
Mon, 12 Sep 2016 23:51:56 +0800
changeset 357130 4569b204d6578b61c7922ae6c517fdc74b7ea0ea
parent 357129 48d5b33726be3f0496b488b93f0820870e42190c
child 357131 29473298207503f040a5d405982338d67db3ff32
push id1324
push usermtabara@mozilla.com
push dateMon, 16 Jan 2017 13:07:44 +0000
treeherdermozilla-release@a01c49833940 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmaug
bugs1299199
milestone51.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 1299199 - Part 2: Remove 'sendPointerEvent' from mochitest_support_external.js. f=btseng, r=smaug
dom/events/test/pointerevents/mochitest_support_external.js
--- a/dom/events/test/pointerevents/mochitest_support_external.js
+++ b/dom/events/test/pointerevents/mochitest_support_external.js
@@ -37,36 +37,16 @@ if(testObj["status"] != testObj["PASS"])
 function completion_function() {
   console.log("w3c tests have been finished");
   if(!SimpleTest._stopOnLoad) {
     console.log("Finishing Mochitest system");
     SimpleTest.finish();
   }
 }
 
-// Helper function to send PointerEvent with different parameters
-function sendPointerEvent(int_win, elemId, pointerEventType, inputSource, params) {
-  var elem = int_win.document.getElementById(elemId);
-  if(!!elem) {
-    var rect = elem.getBoundingClientRect();
-    var eventObj = {type: pointerEventType, inputSource: inputSource};
-    if(params && "button" in params)
-      eventObj.button = params.button;
-    if(params && "isPrimary" in params)
-      eventObj.isPrimary = params.isPrimary;
-    else if(MouseEvent.MOZ_SOURCE_MOUSE == inputSource)
-      eventObj.isPrimary = true;
-    console.log(elemId, eventObj);
-    var salt = ("pointermove" == pointerEventType) ? 1 : 2;
-    synthesizePointer(elem, rect.width*salt/5, rect.height/2, eventObj, int_win);
-  } else {
-    is(!!elem, true, "Document should have element with id: " + elemId);
-  }
-}
-
 // Helper function to send MouseEvent with different parameters
 function sendMouseEvent(int_win, elemId, mouseEventType, params) {
   var elem = int_win.document.getElementById(elemId);
   if(!!elem) {
     var rect = elem.getBoundingClientRect();
     var eventObj = {type: mouseEventType};
     if(params && "button" in params)
       eventObj.button = params.button;