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

Side by Side Diff: third_party/WebKit/LayoutTests/fast/css/pseudo-active-display-none.html

Issue 2095833003: :active pseudo class is not applied for element with display none. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated test case which require LocalStyleChange calculation from both setActive and setHover Created 4 years, 5 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 | third_party/WebKit/LayoutTests/fast/css/pseudo-hover-active-display-none.html » ('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 <!DOCTYPE html>
2 <script src="../../resources/testharness.js"></script>
3 <script src="../../resources/testharnessreport.js"></script>
4 <style>
5 label {
6 background-color: black;
7 }
8 input:active + label {
9 background-color: red;
10 }
11 #nodisplay {
12 display: none;
13 }
14 </style>
15 <input id="nodisplay" type="checkbox"/>
16 <label id="label1" for="nodisplay">The target input has its display set to none. </label>
17 <script>
18 test(function() {
19 assert_true(window.eventSender !== null);
20 }, "window.eventSender is required for the test to run");
21
22 test(function() {
23 var l1 = document.getElementById("label1");
24 var x = l1.offsetLeft + l1.offsetWidth/2;
25 var y = l1.offsetTop + l1.offsetHeight/2;
26 eventSender.mouseMoveTo(x, y);
27 eventSender.mouseDown();
28 assert_equals(getComputedStyle(l1).backgroundColor, 'rgb(255, 0, 0)');
29 eventSender.mouseUp();
30 assert_equals(getComputedStyle(l1).backgroundColor, 'rgb(0, 0, 0)');
31 }, "This test performs a check for active pseudo class to be applied for element when its display is set to none.");
32 </script>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/fast/css/pseudo-hover-active-display-none.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698