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

Side by Side Diff: third_party/WebKit/LayoutTests/shadow-dom/event-composed-ua.html

Issue 2490883002: Make UA dblclick events composed events (Closed)
Patch Set: update Created 4 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/events/Event.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <script src="../resources/testharness.js"></script> 2 <script src="../resources/testharness.js"></script>
3 <script src="../resources/testharnessreport.js"></script> 3 <script src="../resources/testharnessreport.js"></script>
4 <script src="resources/shadow-dom.js"></script> 4 <script src="resources/shadow-dom.js"></script>
5 5
6 <input id="input"></input> 6 <input id="input"></input>
7 <div id="sandbox"> 7 <div id="sandbox">
8 <div id = "host"> 8 <div id = "host">
9 <template> 9 <template>
10 <input id="target" value="test"></div> 10 <input id="target" value="test"></div>
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 assert_true(e.composedPath().includes(target)); 53 assert_true(e.composedPath().includes(target));
54 assert_true(e.composedPath().includes(host)); 54 assert_true(e.composedPath().includes(host));
55 t.done(); 55 t.done();
56 }); 56 });
57 } 57 }
58 }, 'Only certain trusted events should stop in bubbling.'); 58 }, 'Only certain trusted events should stop in bubbling.');
59 59
60 target.select(); 60 target.select();
61 var userError = new Event('error'); 61 var userError = new Event('error');
62 target.dispatchEvent(userError); 62 target.dispatchEvent(userError);
63
64 function doubleClick(x, y) {
65 eventSender.mouseMoveTo(x, y);
66 eventSender.mouseDown();
67 eventSender.mouseUp();
68 eventSender.mouseDown();
69 eventSender.mouseUp();
70 }
71
72 async_test((test) => {
73 input.addEventListener('dblclick', test.step_func_done((e) => {
74 assert_true(e.composed);
75 }));
76 }, 'A dblclick event should be a composed event');
77
78 doubleClick(input.offsetLeft, input.offsetTop);
63 </script> 79 </script>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/events/Event.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698