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

Side by Side Diff: LayoutTests/fast/forms/textarea-selection-preservation.html

Issue 58533003: Move fast/js/resources files to resources. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 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 | Annotate | Revision Log
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script src="../js/resources/js-test-pre.js"></script> 3 <script src="../../resources/js-test.js"></script>
4 </head> 4 </head>
5 <body> 5 <body>
6 <p>This tests for problems where we'd lose the selection in a textarea when maki ng style and value changes.</p> 6 <p>This tests for problems where we'd lose the selection in a textarea when maki ng style and value changes.</p>
7 <div id="console"></div> 7 <div id="console"></div>
8 <p><textarea id="ta">abc123 8 <p><textarea id="ta">abc123
9 </textarea></p> 9 </textarea></p>
10 <script type="text/javascript"> 10 <script type="text/javascript">
11 var ta = document.getElementById('ta'); 11 var ta = document.getElementById('ta');
12 ta.selectionStart = 3; 12 ta.selectionStart = 3;
13 ta.selectionEnd = 4; 13 ta.selectionEnd = 4;
(...skipping 21 matching lines...) Expand all
35 ta.setAttribute("style", "background-color: yellow"); 35 ta.setAttribute("style", "background-color: yellow");
36 shouldBe('ta.selectionStart', '3'); 36 shouldBe('ta.selectionStart', '3');
37 shouldBe('ta.selectionEnd', '4'); 37 shouldBe('ta.selectionEnd', '4');
38 debug("- set value to same value"); 38 debug("- set value to same value");
39 ta.value = "abc123"; 39 ta.value = "abc123";
40 shouldBe('ta.selectionStart', '3'); 40 shouldBe('ta.selectionStart', '3');
41 shouldBe('ta.selectionEnd', '4'); 41 shouldBe('ta.selectionEnd', '4');
42 </script> 42 </script>
43 </body> 43 </body>
44 </html> 44 </html>
OLDNEW
« no previous file with comments | « LayoutTests/fast/forms/textarea-rows-cols.html ('k') | LayoutTests/fast/forms/textarea-set-defaultvalue-after-value.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698