LibWeb: Factor out conditions for creation of inline continuation

Having one big `if` to determine whether or not we should restructure an
inline layout node became a bit unwieldy. This extracts the logic into a
separate method.
This commit is contained in:
Jelle Raaijmakers 2025-02-19 10:54:44 +01:00 committed by Andreas Kling
commit 0c58dad7a6
Notes: github-actions[bot] 2025-02-19 12:50:25 +00:00
3 changed files with 31 additions and 6 deletions

View file

@ -1,5 +1,6 @@
/*
* Copyright (c) 2018-2023, Andreas Kling <andreas@ladybird.org>
* Copyright (c) 2025, Jelle Raaijmakers <jelle@ladybird.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
@ -265,6 +266,8 @@ public:
GC::Ptr<NodeWithStyleAndBoxModelMetrics> continuation_of_node() const { return m_continuation_of_node; }
void set_continuation_of_node(Badge<TreeBuilder>, GC::Ptr<NodeWithStyleAndBoxModelMetrics> node) { m_continuation_of_node = node; }
bool should_create_inline_continuation() const;
void propagate_style_along_continuation(CSS::ComputedProperties const&) const;
virtual void visit_edges(Cell::Visitor& visitor) override;