diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:47:29 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:47:29 +0000 |
commit | 0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d (patch) | |
tree | a31f07c9bcca9d56ce61e9a1ffd30ef350d513aa /layout/reftests/layers/forced-bg-color-outside-visible-region.html | |
parent | Initial commit. (diff) | |
download | firefox-esr-0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d.tar.xz firefox-esr-0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d.zip |
Adding upstream version 115.8.0esr.upstream/115.8.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'layout/reftests/layers/forced-bg-color-outside-visible-region.html')
-rw-r--r-- | layout/reftests/layers/forced-bg-color-outside-visible-region.html | 105 |
1 files changed, 105 insertions, 0 deletions
diff --git a/layout/reftests/layers/forced-bg-color-outside-visible-region.html b/layout/reftests/layers/forced-bg-color-outside-visible-region.html new file mode 100644 index 0000000000..fe7d75a272 --- /dev/null +++ b/layout/reftests/layers/forced-bg-color-outside-visible-region.html @@ -0,0 +1,105 @@ +<!DOCTYPE html> +<html lang="en" class="reftest-wait" reftest-async-scroll> +<meta charset="utf-8"> +<title>Bug 1266161 - Black boxes during scrolling</title> + +<style type="text/css"> + +html, body { + margin: 0; + height: 100%; +} + +body { + outline: 2px solid white; +} + +#scrollbox { + overflow: auto; + will-change: transform, scroll-position; + height: 500px; + width: 500px; +} + +#scrolled { + padding-top: 1px; + height: 1200px; +} + +p { + height: 20px; + background: white; + margin-top: 16px; +} + +span, em { + display: block; + background: white; + width: 134px; + height: 14px; + margin-top: 32px; +} + +em { + width: 10px; +} + +</style> + +<div id="scrollbox" + reftest-displayport-x="0" + reftest-displayport-y="0" + reftest-displayport-w="500" + reftest-displayport-h="500"> + + <div id="scrolled"> + <p></p> + <p></p> + <p></p> + <span style="margin-top: 48px"></span> + <span style="margin-top: 64px"></span> + <span style="margin-top: 96px"></span> + <span style="margin-top: 96px"></span> + <em></em> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + <span></span> + </div> + +</div> + +<script> + +var scrollbox = document.getElementById("scrollbox"); + +var pos = [ 170, 100, 248, 182, 130, 80 ]; + +var i = 0; +function scrollToNextPos() { + scrollbox.scrollTop = pos[i++]; +} + +scrollToNextPos(); + +window.addEventListener("MozReftestInvalidate", function () { + requestAnimationFrame(function scrollAndScheduleNext() { + scrollToNextPos(); + if (i < pos.length) { + requestAnimationFrame(scrollAndScheduleNext); + } else { + document.documentElement.className = ""; + } + }); +}); + +</script> |