| <script src="../../resources/js-test-pre.js"></script> |
| description("Tests that requestAnimationFrame is throttled in subframes are inside scrolled overflow scroll"); |
| window.jsTestIsAsync = true; |
| function scrollOverflow() |
| debug("Scrolling overflow."); |
| var container = document.getElementById('container'); |
| container.scrollLeft = window.innerWidth + 10; |
| debug("requestAnimationFrame should still not be throttled"); |
| shouldBeFalse("testFrame.contentWindow.internals.isRequestAnimationFrameThrottled()"); |
| testFrame = document.getElementById("testFrame"); |
| debug("Frame is initially inside the viewport so requestAnimationFrame should not be throttled"); |
| shouldBeFalse("testFrame.contentWindow.internals.isRequestAnimationFrameThrottled()"); |
| <iframe id="testFrame" src="resources/requestAnimationFrame-frame.html" onload="runTest()"></iframe> |
| <script src="../../resources/js-test-post.js"></script> |