Closed Bug 830479 Opened 9 years ago Closed 9 years ago

Page down scrolls too far on pages with multiple fixed headers

Categories

(Core :: Layout, defect)

x86_64
macOS
defect
Not set
minor

Tracking

()

RESOLVED FIXED
mozilla21

People

(Reporter: jruderman, Assigned: tnikkel)

References

()

Details

(Keywords: testcase)

Attachments

(2 files)

Bug 780345 fixed the case where a page has a single fixed-position header element.  But if a page has two fixed-position header elements, the lower one seems to be ignored.

I noticed this when using the Pocket web app to read a saved article.
Hmm, GetScrollPortSizeExcludingHeadersAndFooters tries to handle that case.

I can't prioritize this. Feel like scratching your own itch, Jesse? Should be easy :-).
GetScrollPortSizeExcludingHeadersAndFooters finds the lowest bottom of all elements that have their top at 0. The example has one element at 0, and a second element at 4px down, so the second element isn't considered.

We could sort the fixed pos elements by top and then consider elements whose top is above the current headerBottom (instead of considering one's whose top is 0). Similarly for footers.
Attached patch patchSplinter Review
Assignee: nobody → tnikkel
Attachment #713765 - Flags: review?(roc)
to fix fatal signed/unsigned comparison warning
https://hg.mozilla.org/integration/mozilla-inbound/rev/4f3625b862a7
https://hg.mozilla.org/mozilla-central/rev/0c10e026f7f3
https://hg.mozilla.org/mozilla-central/rev/4f3625b862a7
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla21
You need to log in before you can comment on or make changes to this bug.