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

Unified Diff: third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html

Issue 2336013002: ScrollRectToVisible should bubble up through its layout container. (Closed)
Patch Set: Modify the test for Mac Created 4 years, 3 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
Index: third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html
diff --git a/third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html b/third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html
new file mode 100644
index 0000000000000000000000000000000000000000..ba45b286922479364547e9b777302d54ebe369d0
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/scrolling/absolute-position-overflow-clip.html
@@ -0,0 +1,23 @@
+<!DOCTYPE html>
+<script src="../../resources/testharness.js"></script>
+<script src="../../resources/testharnessreport.js"></script>
+<body>
+ <div style="overflow-x: hidden;">
+ <div id = "mydiv" style="position: absolute;" />
+ </div>
+</body>
+<script type="text/javascript">
+window.onload = function() {
+ for (var i = 0; i < 500; ++i) {
+ var br = document.createElement('br');
+ document.getElementById("mydiv").appendChild(br);
+ }
+
+ test(function(t) {
+ var focusable = document.createElement("input");
+ document.getElementById("mydiv").appendChild(focusable);
bokan 2016/09/13 14:38:46 The test would be more clear if you didn't dynamic
+ focusable.focus();
+ assert_not_equals(window.scrollY, 0);
+ }, "Tests that for an element with absolute position and whose parent has overflowclip, it can still scroll automatically.");
+}
+</script>

Powered by Google App Engine
This is Rietveld 408576698