Closed Bug 1650799 Opened 5 years ago Closed 5 years ago

Write a mochitest for bug 1647156

Categories

(Core :: Panning and Zooming, task)

task

Tracking

()

RESOLVED FIXED
mozilla80
Tracking Status
firefox80 --- fixed

People

(Reporter: kats, Assigned: kats)

References

Details

Attachments

(1 file)

Nical wrote a patch that caused a perma-checkerboarding regression. He fixed it in bug 1647156 but we should add a test.

The relevant points in the scenario that was perma-checkerboarding were:

  • there was a scrollframe inside a svg filter, so APZ got a scrollinfo layer for it
  • during a repaint request, APZ computed zero margins for it, because scrollinfo
  • The main-thread code to apply the margins and alignment and come up with a final displayport had a posAlignment > sizeAlignment. This meant that even though the size was aligned up to the next 128, the position was aligned down to previous 512, so the "increase" due to size alignment wasn't enough to completely cover the "decrease" due to the pos alignment. With zero margins this meant part of the scroller was left uncovered by the displayport.

I constructed a test that reproduces the problem for me locally, here is a try push (with nical's patch reverted) to verify it fails on try too: https://treeherder.mozilla.org/#/jobs?repo=try&revision=37c39626aaeba0d5857d4615ea95ba2ba53888dc

(Note that the test only fails with --enable-webrender because that's the branch on which the posAlignment/sizeAlignment stuff was split).

Ok, so the test fails for me locally because I'm on a retina mac and the devicePixelRatio is 2.0. On my Linux machine that's not the case and so the test passes because the numbers come out differently. In order to reproduce the failure on Linux I basically need to 2x the height of the scrollframe and scrolled content in the test, but then it's also taller than the browser window and the checkerboarding part is not actually user-visible.

Also on Linux the scrollbars take up layout space and so I need to adjust the numbers a bit more to account for that.

Pushed by kgupta@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/fa82c9fcd9e2 Add a mochitest to cover some of the displayport calculation code. r=nical
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla80
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: