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

Side by Side Diff: LayoutTests/fast/forms/range/range-keyboard-oninput-event.html

Issue 178593003: Dispatch input event for Range element keyboard event (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 10 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
« no previous file with comments | « no previous file | LayoutTests/fast/forms/range/range-keyboard-oninput-event-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <html>
2 <head>
3 <script>
4
5 function sendKey(element, keyName) {
6 var event = document.createEvent('KeyboardEvent');
7 event.initKeyboardEvent('keydown', true, true, document.defaultV iew, keyName);
8 element.dispatchEvent(event);
9 }
10 function log(msg)
11 {
12 var res = document.getElementById('res');
13 res.innerHTML = res.innerHTML + msg + "<br>";
14 }
15 function test()
16 {
17 var slider = document.getElementById('slider');
18 if (window.testRunner) {
19 testRunner.dumpAsText();
20 // slider drag
21 sendKey(slider, 'Left');
22 sendKey(slider, 'Right');
23
24 }
25 }
26 </script>
27 </hefad>
ltilve 2014/02/25 23:52:21 I think that you have a typo here.
Habib Virji 2014/02/26 08:52:57 Done.
28 <body onload="test()">
29 This tests that range generates oninput when in focus for keyboard event and when onblur or out of focus generates for keyboard events.
30 <input type="range" id="slider" oninput="log('input')" onchange="log('ch ange')" min=0 max=100 value=50>
31 <div id="res"></div>
32 </body>
33 </html>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/forms/range/range-keyboard-oninput-event-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698