Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Unified Diff: LayoutTests/fast/forms/range/slider-transformed.html

Issue 1234613004: Only execute default actions on trusted events. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master_event_trusted_main3
Patch Set: Add Yosemite exceptions Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/fast/forms/listbox-onchange.html ('k') | LayoutTests/fast/forms/range/slider-zoomed.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/forms/range/slider-transformed.html
diff --git a/LayoutTests/fast/forms/range/slider-transformed.html b/LayoutTests/fast/forms/range/slider-transformed.html
index 03f6222138667b626ad39ab4851fb100546dea68..de8317168e4bf7ddaa1f8d8c1078ac8054ec8347 100644
--- a/LayoutTests/fast/forms/range/slider-transformed.html
+++ b/LayoutTests/fast/forms/range/slider-transformed.html
@@ -17,19 +17,14 @@
if (window.testRunner)
testRunner.dumpAsText();
- function dispatchEvent(eventType, clientX, clientY)
- {
- var ev = document.createEvent("MouseEvent");
- ev.initMouseEvent(eventType, true, true, window, 1, 1, 1, clientX, clientY, false, false, false, false, 0, document);
- var target = document.elementFromPoint(ev.clientX, ev.clientY);
- target.dispatchEvent(ev);
- }
-
function test()
{
// For some reason the slider needs mouseup/mousedown, not just a "click"
- dispatchEvent("mousedown", 61, 71);
- dispatchEvent("mouseup", 61, 71);
+ if (window.eventSender) {
+ eventSender.mouseMoveTo(61, 71);
+ eventSender.mouseDown(0);
+ eventSender.mouseUp(0);
+ }
const expectedValue = 39;
var val = document.getElementById('slider').value;
@@ -47,4 +42,4 @@
<div id="results">
</div>
</body>
-</html>
+</html>
« no previous file with comments | « LayoutTests/fast/forms/listbox-onchange.html ('k') | LayoutTests/fast/forms/range/slider-zoomed.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698