mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 23:58:11 +00:00
LibWeb: Don't discard update_style_recursively() return value
This was causing us to miss layout invalidations. With this fixed, we can remove the invalidation from Element::recompute_style() along with the associated FIXME. Thanks to Idan for spotting this! :^)
This commit is contained in:
parent
bec0c96aea
commit
d71b0e4638
2 changed files with 2 additions and 5 deletions
|
@ -595,7 +595,7 @@ void Document::update_layout()
|
|||
m_layout_update_timer->stop();
|
||||
}
|
||||
|
||||
static bool update_style_recursively(DOM::Node& node)
|
||||
[[nodiscard]] static bool update_style_recursively(DOM::Node& node)
|
||||
{
|
||||
bool needs_relayout = false;
|
||||
|
||||
|
@ -613,7 +613,7 @@ static bool update_style_recursively(DOM::Node& node)
|
|||
}
|
||||
node.for_each_child([&](auto& child) {
|
||||
if (child.needs_style_update() || child.child_needs_style_update())
|
||||
update_style_recursively(child);
|
||||
needs_relayout |= update_style_recursively(child);
|
||||
return IterationDecision::Continue;
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue