Open Bug 1164652 Opened 10 years ago Updated 2 months ago

when updating resolution and scroll position we try to align to existing layer pixels even though they will change at the next paint

Categories

(Core :: Panning and Zooming, defect, P3)

defect

Tracking

()

People

(Reporter: tnikkel, Unassigned)

Details

(Keywords: perf, Whiteboard: [gfx-noted])

When APZCCallbackHelper::UpdateRootFrame updates layout from the async values it sets a new resolution and instructs the scroll frame to scroll to the new offset. nsGfxScrollFrame goes to great length to try to make sure that it scrolls by an integer number of layer pixels using ClampAndAlignWithLayerPixels. But it uses the values from the last paint. If the resolution is changing this is counterproductive.
First noted in bug 1162648 comment 12.
This should only be an issue on the paints where the resolution changes from its previous value, i.e. the first paint after the user finishes a zoom. During normal panning, whether at initial zoom or after zooming, this should not be an issue. Given it only impacts a small number of situations I'm not sure it's worth bothering with. Or did i misunderstand the problem?
Whiteboard: [gfx-noted]
I ran into the Fennec version of this in December when I was looking into bug 1009306. I wanted to make zooming re-align the scroll position with the origin (such that scrolling to the top / left edge wouldn't change layer pixel alignment), and it didn't work because it was using the old resolution. Looking at the wip patch I have from then, it seems I just hacked around it, so I can't offer a fix.
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.