Closed Bug 1367647 Opened 2 years ago Closed 2 years ago
stylo: have a way to request a restyle that recascades the entire tree
We need some way to request that cascading of a tree's descendants happens even when there is no restyle hint indicating we need to re-selector match, and when the parent's style didn't change. This is so that we can handle changes to, for example, system colors, which affect the style value computation process. This is the second part of (3) in bug 1334732.
Bobby's suggestion in bug 1334732 comment 0 is to expand the current boolean that determines whether we must cascade children into a CascadeHint. Although I think it would work just as well as new RestyleHint flags.
Attachment #8872247 - Flags: review?(emilio+bugs)
Comment on attachment 8872247 [details] style: Support a restyle hint that indicates all descendants must be recascaded. https://reviewboard.mozilla.org/r/143734/#review147520 ::: servo/components/style/restyle_hints.rs:422 (Diff revision 1) > + // inherited values after restyling for animations, and thus we > + // want to remove it so that we don't later try to restyle the element > + // during a normal restyle. (We could have separate > + // RECASCADE_SELF_NORMAL and RECASCADE_SELF_ANIMATIONS flags to make it > + // clear, but this isn't currently necessary.) > + self.recascade.remove(RECASCADE_SELF); Hmm... This is indeed tricky, but I guess it's fine. Thanks for the comment.
Attachment #8872247 - Flags: review?(emilio+bugs) → review+
Comment on attachment 8872248 [details] Bug 1367647 - Test expectation updates. https://reviewboard.mozilla.org/r/143736/#review147522
Attachment #8872248 - Flags: review?(emilio+bugs) → review+
Attachment #8872247 - Attachment is obsolete: true
Pushed by email@example.com: https://hg.mozilla.org/integration/autoland/rev/d43415e71e01 Test expectation updates. r=emilio
You need to log in before you can comment on or make changes to this bug.