1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:18:11 +00:00

LibWeb: Keep track of the parent of each formatting context

This will allow us to find the containing block formatting context
when needed later on.
This commit is contained in:
Andreas Kling 2020-11-25 20:08:52 +01:00
parent 2f491e7769
commit b1e75437c9
9 changed files with 25 additions and 19 deletions

View file

@ -352,7 +352,7 @@ void Document::layout()
m_layout_root = static_ptr_cast<Layout::InitialContainingBlockBox>(tree_builder.build(*this));
}
Layout::BlockFormattingContext root_formatting_context(*m_layout_root);
Layout::BlockFormattingContext root_formatting_context(*m_layout_root, nullptr);
root_formatting_context.run(Layout::LayoutMode::Default);
m_layout_root->set_needs_display();