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

Side by Side Diff: LayoutTests/fast/events/dispatch-synthetic-keyboardevent-no-action.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: 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 unified diff | Download patch
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <script src="../../resources/js-test.js"></script>
3 <p id="description"></p>
4 <select id='top'><option>A</option><option>B</option></select>
5 <pre id="console"></pre>
6 <script>
7 description("Tests to ensure that default action does not occur for untrusted ev ents.");
8
9 function test()
10 {
11 if (window.testRunner)
12 testRunner.dumpAsText();
13
14 var node = document.getElementById('top');
15 var client = node.getBoundingClientRect();
16
17 var event = new KeyboardEvent('keydown', { keyIdentifier: 'Down' } );
tkent 2015/07/17 05:50:41 On Mac, Down key opens the popup. We should dispa
dtapuska 2015/07/21 21:30:05 Done.
18 node.dispatchEvent(event);
19 shouldBeEqualToString("document.getElementById('top').value", "A");
20 }
21
22 test();
23 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698