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

Side by Side Diff: LayoutTests/fast/forms/input-user-select-none.html

Issue 17225002: Make user-select:none not to affect editability (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: 2013-06-19T18:10:01 Created 7 years, 6 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 <head>
2 <style>
3 .sample {
4 -webkit-user-select: none;
5 user-select: none;
6 }
7 </style>
8 </head>
9 <body>
10 <script src="../js/resources/js-test-pre.js"></script>
11 <div id="container">
12 <p id="description"></p>
13 Manual step
14 <ol>
15 <li>Click text input/textarea</li>
16 <li>Type text</li>
17 </ol>
18 <input class="sample" placeholder="edit me!" value=""><br>
19 <textarea class="sample" placeholder="edit me!" ></textarea>
20 </div>
21 <script>
22 description('Tests user-select:none doesn\'t affect editing');
23 function $(id) { return document.getElementById(id); }
24
25 var sample;
26 var expectedText = 'wxy';
27 var samples = document.querySelectorAll('.sample');
28 for (var i = 0; i < samples.length; ++i) {
29 sample = samples[i];
30 sample.focus();
31 if (window.eventSender) {
32 for (var j = 0; j < expectedText.length; ++j)
33 eventSender.keyDown(expectedText[j]);
34 shouldBeEqualToString('sample.value', expectedText);
35 }
36 }
37
38 if (window.testRunner)
39 $('container').outerHTML = '';
40 </script>
41 <script src="../js/resources/js-test-post.js"></script>
42 </body>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698