mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 11:49:44 +00:00
LibWeb: Move image resource request out of ImageStyleValue constructor
This always felt awkward to me, and required a few other hacks to make it work. Now, the request is only started when `load_bitmap()` is called, which we do inside `NodeWithStyle::apply_style()`.
This commit is contained in:
parent
cf3c125e77
commit
0f393771b7
Notes:
sideshowbarker
2024-07-18 02:01:35 +09:00
Author: https://github.com/AtkinsSJ
Commit: 0f393771b7
Pull-request: https://github.com/SerenityOS/serenity/pull/10582
5 changed files with 17 additions and 9 deletions
|
@ -55,7 +55,7 @@ void HTMLBodyElement::parse_attribute(const FlyString& name, const String& value
|
|||
if (color.has_value())
|
||||
document().set_visited_link_color(color.value());
|
||||
} else if (name.equals_ignoring_case("background")) {
|
||||
m_background_style_value = CSS::ImageStyleValue::create(document().parse_url(value), &document());
|
||||
m_background_style_value = CSS::ImageStyleValue::create(document().parse_url(value));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue