LibWeb: Don't drop entire layout tree on media query state change

This isn't actually necessary, since we already invalidate style for the
entire document, and the subsequent style update will discover any
additional layout invalidation needed as well.
This commit is contained in:
Andreas Kling 2025-03-08 17:55:26 +01:00 committed by Andreas Kling
parent 0a300fe59b
commit 067d21b8a4
Notes: github-actions[bot] 2025-03-08 19:22:59 +00:00
2 changed files with 0 additions and 2 deletions

View file

@ -3398,7 +3398,6 @@ void Document::evaluate_media_rules()
if (any_media_queries_changed_match_state) {
style_computer().invalidate_rule_cache();
invalidate_style(StyleInvalidationReason::MediaQueryChangedMatchState);
invalidate_layout_tree(InvalidateLayoutTreeReason::MediaQueryChangedMatchState);
}
}

View file

@ -56,7 +56,6 @@ enum class QuirksMode {
X(HTMLInputElementSrcAttributeChange) \
X(HTMLObjectElement) \
X(KeyframeEffect) \
X(MediaQueryChangedMatchState) \
X(SVGGraphicsElementTransformAttributeChange) \
X(ShadowRootSetInnerHTML)