LibWeb: Return early in clear_floating_boxes()

Get rid of an indentation level. No functional changes.
This commit is contained in:
Jelle Raaijmakers 2025-04-23 10:54:10 +02:00 committed by Andreas Kling
commit 1731389bfe
Notes: github-actions[bot] 2025-04-23 12:26:49 +00:00

View file

@ -909,7 +909,9 @@ BlockFormattingContext::DidIntroduceClearance BlockFormattingContext::clear_floa
auto result = DidIntroduceClearance::No; auto result = DidIntroduceClearance::No;
auto clear_floating_boxes = [&](FloatSideData& float_side) { auto clear_floating_boxes = [&](FloatSideData& float_side) {
if (!float_side.current_boxes.is_empty()) { if (float_side.current_boxes.is_empty())
return;
// NOTE: Floating boxes are globally relevant within this BFC, *but* their offset coordinates // NOTE: Floating boxes are globally relevant within this BFC, *but* their offset coordinates
// are relative to their containing block. // are relative to their containing block.
// This means that we have to first convert to a root-space Y coordinate before clearing, // This means that we have to first convert to a root-space Y coordinate before clearing,
@ -938,7 +940,6 @@ BlockFormattingContext::DidIntroduceClearance BlockFormattingContext::clear_floa
if (!child_box.is_floating()) if (!child_box.is_floating())
float_side.clear(); float_side.clear();
}
}; };
if (computed_values.clear() == CSS::Clear::Left || computed_values.clear() == CSS::Clear::Both) if (computed_values.clear() == CSS::Clear::Left || computed_values.clear() == CSS::Clear::Both)