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

Side by Side Diff: LayoutTests/fast/forms/autofocus-focus-only-once.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
« no previous file with comments | « LayoutTests/fast/forms/autocomplete.html ('k') | LayoutTests/fast/forms/autofocus-keygen.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <title>basic "autofocus" test</title> 3 <title>basic "autofocus" test</title>
4 <style> 4 <style>
5 input { background:red } 5 input { background:red }
6 input:focus { background:lime } 6 input:focus { background:lime }
7 </style> 7 </style>
8 <script src="../js/resources/js-test-pre.js"></script> 8 <script src="../../resources/js-test.js"></script>
9 <script language="JavaScript" type="text/javascript"> 9 <script language="JavaScript" type="text/javascript">
10 window.jsTestIsAsync = true; 10 window.jsTestIsAsync = true;
11 11
12 function elementBlur() { 12 function elementBlur() {
13 document.getElementById("input1").type = "password"; 13 document.getElementById("input1").type = "password";
14 } 14 }
15 function elementFocus() { 15 function elementFocus() {
16 document.getElementById("input1").type = "text"; 16 document.getElementById("input1").type = "text";
17 } 17 }
18 18
19 function test() { 19 function test() {
20 document.getElementById("input2").focus(); 20 document.getElementById("input2").focus();
21 shouldBe('document.activeElement', 'document.getElementById("input2")'); 21 shouldBe('document.activeElement', 'document.getElementById("input2")');
22 finishJSTest(); 22 finishJSTest();
23 } 23 }
24 </script> 24 </script>
25 </head> 25 </head>
26 <body onload="test()"> 26 <body onload="test()">
27 <input id="input1" type="text" autofocus onblur="elementBlur()" onfocus="element Focus()"/> 27 <input id="input1" type="text" autofocus onblur="elementBlur()" onfocus="element Focus()"/>
28 <br/> 28 <br/>
29 <p>This form control should have a green background and active state:<input id=" input2"> 29 <p>This form control should have a green background and active state:<input id=" input2">
30 <hr> 30 <hr>
31 <pre id="console"> 31 <pre id="console">
32 32
33 </pre> 33 </pre>
34 </body> 34 </body>
35 </html> 35 </html>
OLDNEW
« no previous file with comments | « LayoutTests/fast/forms/autocomplete.html ('k') | LayoutTests/fast/forms/autofocus-keygen.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698