Skip to content

Commit

Permalink
stylo: Do not skip parent display-based style fixups for NAC that is …
Browse files Browse the repository at this point in the history
…not a NAC root

Stylo is currently skipping parent display-based style fixups for all NAC,
whereas we probably only want to do this for NAC roots.

In this patch, we ensure that we skip it for NAC roots, and pseudo-elements,
but not other NAC.
  • Loading branch information
chenpighead committed Aug 31, 2017
1 parent 19cbea2 commit adcd86d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion components/style/gecko/wrapper.rs
Expand Up @@ -1171,7 +1171,9 @@ impl<'le> TElement for GeckoElement<'le> {
// level native anonymous content subtree roots, since they're not
// really roots from the style fixup perspective. Checking that we
// are NAC handles both cases.
self.is_native_anonymous()
self.is_native_anonymous() &&
(self.is_root_of_native_anonymous_subtree() ||
self.implemented_pseudo_element().is_some())
}

unsafe fn set_selector_flags(&self, flags: ElementSelectorFlags) {
Expand Down

0 comments on commit adcd86d

Please sign in to comment.