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

Unified Diff: LayoutTests/fast/scrolling/html-element-client-rect-excludes-scrollbars.html

Issue 1310323003: Update Element methods for root layer scrolling. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Address review comments. Created 5 years, 4 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/scrolling/html-element-client-rect-excludes-scrollbars-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/scrolling/html-element-client-rect-excludes-scrollbars.html
diff --git a/LayoutTests/fast/scrolling/html-element-client-rect-excludes-scrollbars.html b/LayoutTests/fast/scrolling/html-element-client-rect-excludes-scrollbars.html
new file mode 100644
index 0000000000000000000000000000000000000000..01339636fba850a60fb5581a66a83c49206baa32
--- /dev/null
+++ b/LayoutTests/fast/scrolling/html-element-client-rect-excludes-scrollbars.html
@@ -0,0 +1,29 @@
+<!DOCTYPE html>
+<script src="../../resources/js-test.js"></script>
+<style>
+::-webkit-scrollbar {
+ width: 20px;
+ height: 20px;
+}
+#space {
+ height: 1000px;
+ width: 1000px;
+}
+</style>
+<div id="space"></div>
+<script>
+
+description(
+ "Tests that the html element excludes scrollbars when reporting " +
+ "clientWidth and clientHeight, and that it implements scroll() " +
+ "by scrolling the frame.");
+
+var htmlElement = document.documentElement;
+shouldBe("htmlElement.clientWidth", "innerWidth - 20");
+shouldBe("htmlElement.clientHeight", "innerHeight - 20");
+
+htmlElement.scroll(10, 10);
+shouldBe("scrollX", "10");
+shouldBe("scrollY", "10");
+
+</script>
« no previous file with comments | « no previous file | LayoutTests/fast/scrolling/html-element-client-rect-excludes-scrollbars-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698