Closed Bug 1201581 Opened 4 years ago Closed 4 years ago

Fixed-position margins/clip are not updated properly in fennec-apz

Categories

(Firefox for Android :: Toolbar, defect)

All
Android
defect
Not set

Tracking

()

RESOLVED FIXED
Firefox 43
Tracking Status
firefox43 --- fixed

People

(Reporter: kats, Assigned: kats)

References

Details

Attachments

(2 files, 3 obsolete files)

STR:
1. Start a fennec built with --enable-android-apz
2. Load the page at http://people.mozilla.org/~kgupta/bug/1180295.html
3. Put your finger down on the page and scroll downwards slowly

Expected;
As the toolbar slides off the page, the green fixed-pos box at the bottom of the screen should stay stuck to the bottom of the screen

Actual:
It drifts up and there is a white band at the bottom of the screen

This is happening because we're not syncing the FrameMetrics to the ImmutableViewportMetrics per composite like we should be doing. There is a comment to this effect at http://mxr.mozilla.org/mozilla-central/source/gfx/layers/composite/AsyncCompositionManager.cpp?rev=4c8fcc50b299#645 although it's a little out of date.

We do need some sort of syncing code there, although I need to figure out exactly which data needs to be sent from C++ -> Java and which data needs to be sent from Java -> C++
Attached patch WIP (obsolete) — Splinter Review
This makes the fix-pos box stick to the bottom, but the clipping is still not right. I might need to adjust the clip on a different layer. However I'm PTO in the afternoon so stashing this patch here for now.
Attached patch Part 1 - Extract a helper method (obsolete) — Splinter Review
Assignee: nobody → bugmail.mozilla
Attachment #8657183 - Flags: review?(rbarker)
This fixes the issues described in comment 0, by making sure the metrics information are synced between Java and C++ on each composite.
Attachment #8656715 - Attachment is obsolete: true
Attachment #8657185 - Flags: review?(rbarker)
Comment on attachment 8657185 [details] [diff] [review]
Part 2 - Hook up the syncFrameMetrics call

Oh wait I screwed up this patch. It should be using mViewportMetrics and not mFrameMetrics. Let me re-test.
Attachment #8657185 - Flags: review?(rbarker)
Attachment #8657183 - Flags: review?(rbarker) → review+
Rebased, carrying r+
Attachment #8657183 - Attachment is obsolete: true
Attachment #8658330 - Flags: review+
Attachment #8658291 - Flags: review?(rbarker) → review+
https://hg.mozilla.org/mozilla-central/rev/18f719dfea70
https://hg.mozilla.org/mozilla-central/rev/6300571e5c68
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 43
You need to log in before you can comment on or make changes to this bug.