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

Unified Diff: LayoutTests/fast/css/focus-ring-recursive-inlines.html

Issue 1083403005: Don't add duplicated line box rects into focus ring rects (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase again 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/fast/css/focus-ring-recursive-inlines-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/css/focus-ring-recursive-inlines.html
diff --git a/LayoutTests/fast/css/focus-ring-recursive-inlines.html b/LayoutTests/fast/css/focus-ring-recursive-inlines.html
new file mode 100644
index 0000000000000000000000000000000000000000..96c932fdb3eec4dc91703ff64f33ac43053f895d
--- /dev/null
+++ b/LayoutTests/fast/css/focus-ring-recursive-inlines.html
@@ -0,0 +1,31 @@
+<!DOCTYPE html>
+<style>
+#container {
+ width: 200px;
+}
+#inner {
+ position: relative;
+ top: -3px;
+}
+</style>
+<script src="../../resources/js-test.js"></script>
+<script>
+description('When adding focus ring rects, we should avoid adding line box rects of recursive inlines repeatedly');
+onload = function() {
+ document.body.offsetTop;
+ // 6 focus ring rects:
+ // - 0-2: line boxes of the focused span;
+ // - 3: anonymous continuation block;
+ // - 4: the inner block
+ // - 5: root line box of the inner block
+ if (window.testRunner && window.internals)
+ shouldBe("internals.focusRingRects(document.getElementById('focus')).length", "6");
+};
+</script>
+<div id="container">
+ <span id="focus">
+ <b><b><b><i><i><i>INLINE</i></i> <i><i>TEXT</i></i>
+ <div id="inner"><b><b>BLOCK</b> <i>CONTENTS</i></b></div>
+ </i></b></b></b>
+ </span>
+</div>
« no previous file with comments | « no previous file | LayoutTests/fast/css/focus-ring-recursive-inlines-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698