Closed Bug 1101260 Opened 5 years ago Closed 5 years ago

Event regions are only added for stacking contexts

Categories

(Core :: Layout, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla36

People

(Reporter: dvander, Assigned: dvander)

References

Details

Attachments

(2 files, 1 obsolete file)

Currently we only inject nsDisplayLayerEventRegions for stacking and pseudo-stacking contexts. With containerless scrolling, this means that all but the first processed layer as part of a scrollframe will be missing event regions.

<roc> dvander: in BuildDisplayListForChild, we want to push a new nsDisplayEventRegion when nsLayoutUtils::GetAnimatedGeometryRootForFrame returns a different animated geometry root for the parent than for the child
<roc> Before actually shipping that code I think we need to do some work to optimize GetAnimatedGeometryRootForFrmae
Component: Panning and Zooming → Layout
Attached patch bug1101260-event-regions.patch (obsolete) — Splinter Review
This adds an nsDisplayLayerEventRegions item for non-stacking contexts, if they have a different animated geometry root than their parent. The current animated geometry root for a frame is now cached as well.

I had to move some stuff from nsLayoutUtils to nsDisplayList, there was one material change from that. Previously we could return an animated geometry root in between a sticky frame and its nearest scrollframe, and that's been fixed.
Attachment #8525735 - Flags: review?(roc)
Comment on attachment 8525735 [details] [diff] [review]
bug1101260-event-regions.patch

Review of attachment 8525735 [details] [diff] [review]:
-----------------------------------------------------------------

Can you split the patch into "cache animated geometry roots" and "create more nsDisplayEventRegions" please? Thanks!
Attachment #8525735 - Flags: review?(roc)
Comment on attachment 8525759 [details] [diff] [review]
part 1, cache the current animated geometry root

Review of attachment 8525759 [details] [diff] [review]:
-----------------------------------------------------------------

Excellent!!!
Attachment #8525759 - Flags: review?(roc) → review+
We should go further and actually store the animated geometry root in each display item. This would reduce overhead in FrameLayerBuilder. But that shouldn't be in this bug.
https://hg.mozilla.org/mozilla-central/rev/42c5ee6094ee
https://hg.mozilla.org/mozilla-central/rev/b4bff1b4f793
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla36
Depends on: 1103106
Blocks: 1172025
You need to log in before you can comment on or make changes to this bug.