mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-03 21:12:08 +02:00
ImageSetStyleValue::set_style_sheet() previously stored the style sheet on itself but didn't propagate to its candidate images. As a result, candidates were never registered as pending image resources, so their fetches didn't start until layout time and didn't delay the document's load event. This caused css-image-set-background-type.html to be flaky: under load, the screenshot could be captured before the selected SVG candidate had finished decoding, producing an empty box instead of the expected color. Propagate set_style_sheet() to each candidate image whose type() filter does not exclude it, mirroring StyleValueList and ShorthandStyleValue. The candidates now register themselves as pending so SharedResourceRequest's load event delayer correctly delays the load event until decoding completes.
9.2 KiB
9.2 KiB