mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 23:50:19 +00:00
LibWeb: Remove unused argument of InlineLevelIterator::next
Also remove unused method from LineBuilder.
This commit is contained in:
parent
768c35af71
commit
ef6a78518f
Notes:
sideshowbarker
2024-07-17 01:23:08 +09:00
Author: https://github.com/axgallo Commit: https://github.com/SerenityOS/serenity/commit/ef6a78518f Pull-request: https://github.com/SerenityOS/serenity/pull/20610
4 changed files with 6 additions and 8 deletions
|
@ -244,7 +244,7 @@ void InlineFormattingContext::generate_line_boxes(LayoutMode layout_mode)
|
|||
LineBuilder line_builder(*this, m_state);
|
||||
|
||||
for (;;) {
|
||||
auto item_opt = iterator.next(line_builder.available_width_for_current_line());
|
||||
auto item_opt = iterator.next();
|
||||
if (!item_opt.has_value())
|
||||
break;
|
||||
auto& item = item_opt.value();
|
||||
|
|
|
@ -124,7 +124,7 @@ void InlineLevelIterator::skip_to_next()
|
|||
compute_next();
|
||||
}
|
||||
|
||||
Optional<InlineLevelIterator::Item> InlineLevelIterator::next(AvailableSize available_width)
|
||||
Optional<InlineLevelIterator::Item> InlineLevelIterator::next()
|
||||
{
|
||||
if (!m_current_node)
|
||||
return {};
|
||||
|
@ -139,7 +139,7 @@ Optional<InlineLevelIterator::Item> InlineLevelIterator::next(AvailableSize avai
|
|||
if (!chunk_opt.has_value()) {
|
||||
m_text_node_context = {};
|
||||
skip_to_next();
|
||||
return next(available_width);
|
||||
return next();
|
||||
}
|
||||
|
||||
m_text_node_context->next_chunk = m_text_node_context->chunk_iterator.next();
|
||||
|
@ -200,12 +200,12 @@ Optional<InlineLevelIterator::Item> InlineLevelIterator::next(AvailableSize avai
|
|||
|
||||
if (is<Layout::ListItemMarkerBox>(*m_current_node)) {
|
||||
skip_to_next();
|
||||
return next(available_width);
|
||||
return next();
|
||||
}
|
||||
|
||||
if (!is<Layout::Box>(*m_current_node)) {
|
||||
skip_to_next();
|
||||
return next(available_width);
|
||||
return next();
|
||||
}
|
||||
|
||||
if (is<Layout::ReplacedBox>(*m_current_node)) {
|
||||
|
|
|
@ -51,7 +51,7 @@ public:
|
|||
|
||||
InlineLevelIterator(Layout::InlineFormattingContext&, LayoutState&, Layout::BlockContainer const&, LayoutMode);
|
||||
|
||||
Optional<Item> next(AvailableSize available_width);
|
||||
Optional<Item> next();
|
||||
|
||||
private:
|
||||
void skip_to_next();
|
||||
|
|
|
@ -37,8 +37,6 @@ public:
|
|||
return false;
|
||||
}
|
||||
|
||||
AvailableSize available_width_for_current_line() const { return m_available_width_for_current_line; }
|
||||
|
||||
void update_last_line();
|
||||
|
||||
void remove_last_line_if_empty();
|
||||
|
|
Loading…
Reference in a new issue