12022-02-23 Antti Koivisto <antti@apple.com>
2
3 [CSS Container Queries] offsetWidth/Height and similar should update layout for container queries
4 https://bugs.webkit.org/show_bug.cgi?id=237079
5
6 Reviewed by NOBODY (OOPS!).
7
8 Fix
9
10 css/css-contain/container-queries/inline-size-containment.html
11 css/css-contain/container-queries/inline-size-containment-vertical-rl.html
12
13 * dom/Document.cpp:
14 (WebCore::Document::updateLayout):
15
16 Make iterative instead of recursive.
17
18 (WebCore::Document::updateLayoutIfDimensionsOutOfDate):
19
20 Check for query containers.
21 Call local updateLayout instead of the FrameViewLayoutContext one.
22
23 * page/FrameView.cpp:
24 (WebCore::FrameView::updateLayoutAndStyleIfNeededRecursive):
25 * style/StyleScope.cpp:
26 (WebCore::Style::Scope::updateQueryContainerState):
27
28 Add protection against infinite layout/invalidation cycle with unstable layouts.
29
30 * style/StyleScope.h:
31