[@container] Mark elements that depend on container queries as such
The DependsOnContainerQueries flag was already added to ComputedStyle, but until now nothing actually set it (outside unit tests). This CL sets the flag whenever we match a container query-dependent rule (regardless of the result of the query). Note that I'm deliberately avoiding mutation of ComputedStyle directly from ElementRuleCollector, since we're trying to get rid of the mutable reference. Hence the flag is transported via MatchResult instead. Note also that this doesn't quite work correctly for pseudo-elements: we need to mark in PseudoStyleForElements, and also handle dynamic_pseudo matches in ElementRuleCollector, but that will be done in a separate CL. Bug: 1145970 Change-Id: Id48bd88d3f0580c8f58802565bc77a7ff1497d2c Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2627150 Commit-Queue: Anders Hartvoll Ruud <andruud@chromium.org> Reviewed-by:Rune Lillesveen <futhark@chromium.org> Reviewed-by:
Xiaocheng Hu <xiaochengh@chromium.org> Cr-Commit-Position: refs/heads/master@{#843888}
Showing
Please register or sign in to comment