mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-29 04:37:55 +00:00
LibWeb: Pass current target box to BFC::run()
The BFC "context box" is now the outer box of the block formatting context. Previously the context box was always the current target box, which made it hard to reason about who was really the containing block of whom in various places. Note that IFC still has the containing block as its context box, this change only affects BFC. However, to clarify the situation in IFC, I've added a containing_block() getter than returns the context_box().
This commit is contained in:
@@ -40,9 +40,9 @@ BreakNode::~BreakNode()
|
||||
{
|
||||
}
|
||||
|
||||
void BreakNode::split_into_lines(InlineFormattingContext& block, LayoutMode)
|
||||
void BreakNode::split_into_lines(InlineFormattingContext& context, LayoutMode)
|
||||
{
|
||||
block.context_box().add_line_box();
|
||||
context.containing_block().add_line_box();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user