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

Unified Diff: third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-repaint.html

Issue 2727253004: Call getUncachedPseudoStyle on correct node for ::selection. (Closed)
Patch Set: Documentation fixes. Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/LayoutObject.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-repaint.html
diff --git a/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-repaint.html b/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-repaint.html
index d0185bc6f5e5bd43cf252d7380f42eeebf3075e1..d12c6bd1a46d44d800602cd4753c644205b0701f 100644
--- a/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-repaint.html
+++ b/third_party/WebKit/LayoutTests/paint/invalidation/selection/selection-repaint.html
@@ -1,30 +1,31 @@
<!DOCTYPE html>
<style>
- ::selection {
+ #t1::selection {
background-color: transparent;
color: red
}
.green::selection {
- color: green
+ color: green !important
}
</style>
-<span id="t1">This text should be green.</span>
+<span id="t1">This text </span><span id="t2">should be green.</span>
<script>
if (window.testRunner)
testRunner.waitUntilDone();
- function setSelection(textNode) {
+ function setSelection(startNode, endNode) {
window.getSelection().removeAllRanges();
var range = document.createRange();
- range.setStart(textNode, 0);
- range.setEnd(textNode, textNode.data.length);
+ range.setStart(startNode, 0);
+ range.setEnd(endNode, endNode.data.length);
window.getSelection().addRange(range);
}
- setSelection(t1.firstChild);
+ setSelection(t1.firstChild, t2.firstChild);
requestAnimationFrame(() =>
requestAnimationFrame(() => {
t1.className = "green";
+ t2.className = "green";
if (window.testRunner)
testRunner.notifyDone();
}));
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/LayoutObject.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698