Closed Bug 1487181 Opened 6 years ago Closed 3 years ago

Elements with perspective and overflow: scroll set do not properly clip children with active layers

Categories

(Core :: Web Painting, defect, P2)

defect

Tracking

()

RESOLVED FIXED
85 Branch
Tracking Status
firefox85 --- fixed

People

(Reporter: mikokm, Assigned: botond)

References

Details

Attachments

(4 files, 1 obsolete file)

Attached file testcase.html (obsolete) —
Regression from bug 1298218.
Priority: -- → P2

This was recently spotted in the wild (bug 1623864).

Markus, any idea what is going wrong here? This seems a bit similar to bug 1607709.

Flags: needinfo?(mstange)
Attachment #9004989 - Attachment is obsolete: true
Attached file display-list-dump.txt
Flags: needinfo?(mstange)
Blocks: 1458145

ni?myself to try to look into this

Flags: needinfo?(botond)

Here's what I've discovered so far:

  • The clip that we're expecting to be applied visually but isn't, is the subframe's scroll port clip.
  • This clip is present in the display list, in the clip chain of nsDisplayPerspective item (line 18 of the display list dump from comment 4), under the correct ASR (it's the 0x120e284d8 <480,480,6000,6000> [0x12032a230] entry in the clip chain).
  • In the layer tree, we would expect this clip to show up in ScrollMetadata::mScrollClip of the subframe's scroll metadata.
  • The subframe's scroll metadata is present on layer 0x10d671400 (line 39), but it's missing the scroll clip.
  • The scroll clip comes from the clip chain stored in the NewLayerEntry for the layer.
  • For container layers built by display items with active layer state, the clip chain stpred in the NewLayerEntry generally comes from from item's clip chain.
  • However, the item building the layer in question is the nsDisplayTransform child of the nsDisplayPerspective item, not the perspective item itself.

Bascially, I think that whatever mechanism is causing the subframe's scroll metadata to be applied to the transform layer rather than the perspective layer, needs to be applied to the scroll clip as well.

Assignee: nobody → botond
Flags: needinfo?(botond)
Pushed by bballo@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/a0ba207505fb
Fix some include-what-you-use issues. r=mattwoodrow
https://hg.mozilla.org/integration/autoland/rev/2e9878c11e19
Ensure that the scroll metadata of a transform layer child of a perspective layer has the correct scroll clip as well. r=mattwoodrow
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 85 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: