mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 15:37:46 +00:00
LibWeb: Avoid some unnecessary inside layouts during intrinsic sizing
When calculating intrinsic sizes, we don't need to recurse into *every* box and layout its insides. IIUC, we can skip any unconstrained box with definite sizes in both axes. So this patch does exactly that.
This commit is contained in:
parent
3ede8dbffb
commit
83bb16ede3
2 changed files with 16 additions and 1 deletions
|
@ -150,7 +150,8 @@ void InlineFormattingContext::dimension_box_on_line(Box const& box, LayoutMode l
|
|||
box_state.set_content_height(height_value.resolved(box, container_height).to_px(inline_block));
|
||||
}
|
||||
|
||||
independent_formatting_context->parent_context_did_dimension_child_root_box();
|
||||
if (independent_formatting_context)
|
||||
independent_formatting_context->parent_context_did_dimension_child_root_box();
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue