DescriptionUnify predicates for elements "contributing" to a <clipPath>
LayoutSVGResourceClipper has four loops that iterate the child elements
that contribute to the clip path. They are however all subtly different.
To remedy this and make it more obvious that the same set of elements
are iterated, add a helper contributesToClip(...) that handles the
checking of if an element is considered to be contributing to the clip
path or not. This yields four loops with a very similar structure.
Also move path-extraction to a helper, use helpers from Traversal<...>
for basic iteration, drop LayoutObject/ComputedStyle related checks
from the SVGUseElement helper (now handled elsewhere) and hoist the
PaintInfo out of the loop in createContentPicture since it is invariant.
Committed: https://crrev.com/9fa2375bf1a676c4bb8d6b7aa56ff70b30769819
Cr-Commit-Position: refs/heads/master@{#436703}
Patch Set 1 #
Messages
Total messages: 13 (8 generated)
|