Bug 1174323 part 2 - Use native mouse move to improve robustness of screenClientXYConst subtest. r=smaug

This commit is contained in:
Xidorn Quan 2016-01-13 10:29:09 +11:00
parent 8831e8c206
commit 0d0abeb2ab
2 changed files with 6 additions and 11 deletions

View File

@ -88,9 +88,8 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=633602
div.removeEventListener("mousemove", moveUnlocked, false);
div.addEventListener("mousemove", moveLocked, false);
divRect = div.getBoundingClientRect();
synthesizeMouse(div, (divRect.width / 4) * 3, (divRect.height / 4) * 3, {
type: "mousemove"
}, window);
synthesizeNativeMouseMove(div, (divRect.width / 4) * 3,
(divRect.height / 4) * 3);
}
}, false);
@ -105,11 +104,11 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=633602
setTimeout(fullscreenchange, 250);
return;
}
// Synthesize mouse event asynchronously
SimpleTest.executeSoon(function () {
synthesizeNativeMouseMove(div, 0, 0, () => {
div.addEventListener("mousemove", moveUnlocked, false);
synthesizeMouseAtCenter(div, { type: "mousemove" }, window);
}, 0);
divRect = div.getBoundingClientRect();
synthesizeNativeMouseMove(div, divRect.width / 2, divRect.height / 2);
});
} else {
runTests();
SimpleTest.finish();

View File

@ -59,10 +59,6 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=633602
];
var gDisableList = [
// Bug 1174323
{ file: "file_screenClientXYConst.html", platform: "MacIntel" },
{ file: "file_screenClientXYConst.html", platform: "Win32" },
{ file: "file_screenClientXYConst.html", platform: "Win64" },
];
var gTestWindow = null;