DescriptionSchedule a type selector invalidation set for RuleSet invalidations.
We marked all elements which had a selector in the tagRules bucket for
style recalc for RuleSet invalidations. That means we would recalculate
style for all spans if we added a stylesheet containing a rule with an
"#id span" selector (but not for "#id span.class" as that ends up in
the classRules bucket).
Instead, use an invalidation set containing only tag names for the
selectors where there are no ids, classes, or attribute selectors, and
which have a type selector in the rightmost compound. This means that
"#id span" will not add "span" to that set, but "span" and "div span"
will. "div span" will not add "div", and "div *" will cause a full
scope recalc. In order to support invalidation for those, we would have
had to have one invalidation set for each tag name instead of a single
descendant invalidation set for all.
RuleSet invalidations schedule this typeRuleInvalidationSet on the root
of the TreeScope When doing ruleset invalidations.
BUG=680549
Review-Url: https://codereview.chromium.org/2703643003
Cr-Commit-Position: refs/heads/master@{#451488}
Committed: https://chromium.googlesource.com/chromium/src/+/a04a994fb4146b480a2fb4c0505679fc1e1d857a
Patch Set 1 #Patch Set 2 : Rebased #Patch Set 3 : Added layout tests #Patch Set 4 : Corrected expectation text. #
Depends on Patchset: Dependent Patchsets: Messages
Total messages: 23 (16 generated)
|