Skip to content

Commit 9561ea3

Browse files
committed
Bug 1903785 [wpt PR 46843] - [container] Clear skipped style recalc for all descendants, a=testonly
Automatic update from web-platform-tests [container] Clear skipped style recalc for all descendants The existing code assumed we would always resume style recalc from the skipped container's layout, but that is not always the case. Take the following scenario which could happen with nested containers: 1. Style recalc is not skipped for an outer container because it is not marked for layout. 2. Style recalc is skipped for an inner container because it is marked for layout. 3. Layout changes the width of the outer container because the outer container is auto-sized, and changes size because an ancestor box changes its size. 4. The container evaluation changes for the outer container, which means we enter UpdateStyleAndLayoutTreeForContainer() for the outer container. 5. We reach recalc for the inner container, whose subtree was skipped for style recalc, but we did not clear the skipping or retrieve the stored style recalc change. In this CL we always check, clear, and return the StyleRecalcChange if style recalc was skipped. Bug: 346264227 Change-Id: I3dc997850068a6751333ed588adf2f1f0e87518f Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5630638 Reviewed-by: Anders Hartvoll Ruud <andruudchromium.org> Commit-Queue: Rune Lillesveen <futharkchromium.org> Cr-Commit-Position: refs/heads/main{#1317345} -- wpt-commits: 1ec7cf9a1bf651899999bab7f99e09d48416d708 wpt-pr: 46843 UltraBlame original commit: 696f886dc75ad5522b5492a76245492f2e9d49bd
1 parent 0a3023e commit 9561ea3

File tree

1 file changed

+150
-0
lines changed

1 file changed

+150
-0
lines changed
Lines changed: 150 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,150 @@
1+
<
2+
!
3+
DOCTYPE
4+
html
5+
>
6+
<
7+
title
8+
>
9+
Chrome
10+
crash
11+
bug
12+
346264227
13+
<
14+
/
15+
title
16+
>
17+
<
18+
link
19+
rel
20+
=
21+
"
22+
help
23+
"
24+
href
25+
=
26+
"
27+
https
28+
:
29+
/
30+
/
31+
crbug
32+
.
33+
com
34+
/
35+
346264227
36+
"
37+
>
38+
<
39+
style
40+
>
41+
container
42+
(
43+
width
44+
=
45+
0px
46+
)
47+
{
48+
#
49+
inner
50+
{
51+
display
52+
:
53+
none
54+
;
55+
}
56+
}
57+
<
58+
/
59+
style
60+
>
61+
<
62+
div
63+
style
64+
=
65+
"
66+
container
67+
-
68+
type
69+
:
70+
inline
71+
-
72+
size
73+
"
74+
>
75+
<
76+
div
77+
id
78+
=
79+
"
80+
inner
81+
"
82+
style
83+
=
84+
"
85+
container
86+
-
87+
type
88+
:
89+
inline
90+
-
91+
size
92+
;
93+
display
94+
:
95+
none
96+
"
97+
>
98+
<
99+
span
100+
>
101+
<
102+
/
103+
span
104+
>
105+
<
106+
/
107+
div
108+
>
109+
<
110+
/
111+
div
112+
>
113+
<
114+
script
115+
>
116+
document
117+
.
118+
body
119+
.
120+
offsetTop
121+
;
122+
document
123+
.
124+
body
125+
.
126+
style
127+
.
128+
width
129+
=
130+
0
131+
;
132+
inner
133+
.
134+
style
135+
.
136+
display
137+
=
138+
"
139+
"
140+
;
141+
document
142+
.
143+
body
144+
.
145+
offsetTop
146+
;
147+
<
148+
/
149+
script
150+
>

0 commit comments

Comments
 (0)