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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/misc/resources/cross-origin-subframe-for-scrolling.html

Issue 2631853002: Give OOPIF FrameViews their own scroll animation timelines and hosts (Closed)
Patch Set: Fixes from bokan comments Created 3 years, 11 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/LayoutTests/http/tests/misc/scroll-cross-origin-iframes.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/misc/resources/cross-origin-subframe-for-scrolling.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/misc/resources/cross-origin-subframe-for-scrolling.html b/third_party/WebKit/LayoutTests/http/tests/misc/resources/cross-origin-subframe-for-scrolling.html
new file mode 100644
index 0000000000000000000000000000000000000000..75414848f7d7422ede192739fff1dab2f4cf88fa
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/http/tests/misc/resources/cross-origin-subframe-for-scrolling.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<script src="/js-test-resources/js-test.js"></script>
+<div style="height: 300px"></div>
+
+<script>
+setPrintTestResultsLazily();
+self.jsTestIsAsync = true;
+
+window.onload = (() => {
+ if (!window.eventSender || !window.internals) {
+ debug("This test requires window.eventSender.");
+ return;
+ }
+ internals.settings.setScrollAnimatorEnabled(true);
+});
+
+function handleMessage(event) {
+ if (event.data.hasOwnProperty('scrollBy')) {
+ eventSender.mouseMoveTo(event.data.left + 5, event.data.top + 5);
+ eventSender.mouseScrollBy(0, event.data.scrollBy);
+ requestAnimationFrame(() => {setTimeout(() => {event.source.postMessage("", "*")}, 500)});
+ } else {
+ event.source.postMessage({scrollTop: document.documentElement.scrollTop}, "*");
+ }
+}
+
+window.addEventListener("message", handleMessage);
+</script>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/misc/scroll-cross-origin-iframes.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698