DescriptionSkip child ShadowRoots when invalidation does not have boundary crossing rules
When the only things that changed are not tree boundary crossing rules we
can skip invalidation in descendant ShadowRoots. This means that
if you have lots of nested components with duplicate class names then using
a descendant selector in an enclosing component won't invalidate style in
nested ShadowRoots.
I also packed the booleans on DescendantInvalidationSet since we keep growing
it with new flags.
In the future we can make this tree boundary crossing logic even smarter so that
if you have both tree boundary and not tree boundary crossing invalidation
sets on the same subtree we can skip running the non-tree boundary crossing
rules when recursing into a ShadowRoot.
I also took this as an opportunity to clean up the addFeaturesToInvalidationSets
logic and merged the new treeBoundaryCrossing flag and the wholeSubtreeInvalid
flag into the InvalidationSetFeatures.
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=175171
Patch Set 1 #Patch Set 2 : Add a test #Patch Set 3 : fix the test #Patch Set 4 : fix set merging #
Total comments: 10
Patch Set 5 : Move checks per review #
Total comments: 1
Patch Set 6 : Use switches and fall through #Patch Set 7 : no really #
Total comments: 3
Patch Set 8 : fix typo #Patch Set 9 : fix build #
Messages
Total messages: 8 (0 generated)
|