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

Side by Side Diff: LayoutTests/fast/forms/hover-on-moving-mouse-checkbox-to-parent-label.html

Issue 1064543002: Set hovered state of current Hovered node even if it is also common ancestor of oldHovered node and (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 8 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>
tkent 2015/04/07 03:41:44 Please move this test to LayoutTests/fast/forms/la
2 <html>
3 <head>
4 <script src="../../resources/js-test.js"></script>
5 <script>
6 function startTest() {
7 var label = document.getElementById("label");
8 var checkbox = document.getElementById("checkbox");
9
10 // Move mouse to checkbox.
11 if (window.eventSender)
12 eventSender.mouseMoveTo(23, 70 );
tkent 2015/04/07 03:41:44 Inconsistent indentation. This file uses 4-space
13 var resStr = window.getComputedStyle(checkbox, ':after').getPropertyValue('c ontent');
tkent 2015/04/07 03:41:44 Please don't use :after for INPUT elements. It sh
14
15 // Move mouse to text after checkbox.
16 if (window.eventSender)
17 eventSender.mouseMoveTo(60, 75);
tkent 2015/04/07 03:41:44 Inconsistent indentation.
18 var resStrMoved = window.getComputedStyle(checkbox, ':after').getPropertyVal ue('content');
19
20 shouldBeEqualToString(resStr, "Hovering");
21 shouldBeEqualToString(resStrMoved, "Hovering");
22 }
23
24 </script>
25 <style>
26 div {
27 position:relative;
28 top:10px;
29 left:10px;
30 }
31 input[type=checkbox]:hover:after {
32 content: 'Hovering';
tkent 2015/04/07 03:41:45 Inconsistent indentation.
33 top: 2em;
34 position:relative;
35 background-color:red;
36 }
37 </style>
38 <body onload="startTest()">
39 <div>
40 <label id="label"><input id="checkbox" type="checkbox"/> Test</label>
41 </div>
42 </body>
43 </head>
44 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698