Closed Bug 1145263 Opened 9 years ago Closed 8 years ago
Absolutely positioned element disappears when scrollbox gets active APZ scrolling (absolute element is child of scrolled container layer and positioned outside the scrollbox)
If you start scrolling the scrollbox with the black border, the element with the blue border disappears.
(Note that we didn't even draw the abspos item until bug 1119117.) I think the clip that we get from SetupScrollingMetadata is to blame. We don't need that, and I don't think we should be adding it when we don't have some kind of async scrolling enabled. But that still means we have the problem with async scrolling. The container layer is for the opacity div, and so it's animated geometry root is the scrollbox during active scrolling. But it can contain painted layers that have their AGR as the scrollbox (non abs-pos content inside the opacity div) and painted layers that have their AGR as the root scroll frame (the abs-pos element). So we simply can't set a clip on the opacity container layer. We need to set different clips on the child painted layers in order to do it properly.
Here is what I think we should do. Only assign framemetrics and set clip rects on leaf layers. Container layers may contain content that is contained by an active scroll frame, and content that is not. (scrollinfo layers are a special case, they are a container layer with no children, so a leaf layer). I don't know if AZPC can handle this without changes though.
When I load the test case in B2G it looks like this, both with and without the patch. In neither case do I see the rect in the top-left.
As mentioned on IRC this patch has at least one regression on B2G - if you load the reference-workload-medium, go into the contacts app, go into a contact's details and scroll, the photo doesn't get clipped properly. "Barbara L. Chandler" is a contact for example where this happens, with the robot-head contact photo.
The attached testcase was fixed by the landing of bug 1148582. Not sure if it can be checked in as a reftest or not, though?
It could be converted into a reftest with a few small tweaks. But on my machine the testcase still fails in today's nightly (e10s + APZ on). Do you know why we are getting different results?
Flags: needinfo?(mstange) → needinfo?(ryanvm)
Ah, I have APZ disabled. Which would have also been the case for nightlies back in the late-May timeframe, which explains why the testcase worked with mozregression as well. Guess we should reopen this then, but change scope to reflect that APZ is required to reproduce?
Sounds good to me.
Assignee: dvander → nobody
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Summary: Absolutely positioned element disappears when scrollbox gets active scrolling (absolute element is child of scrolled container layer and positioned outside the scrollbox) → Absolutely positioned element disappears when scrollbox gets active APZ scrolling (absolute element is child of scrolled container layer and positioned outside the scrollbox)
Target Milestone: mozilla42 → ---
Bug 1147673 fixed this.
Assignee: nobody → mstange
Status: NEW → RESOLVED
Closed: 9 years ago → 8 years ago
Depends on: 1147673
Resolution: --- → FIXED
Target Milestone: --- → mozilla46
You need to log in before you can comment on or make changes to this bug.