LibGUI: Remove Model::sibling() since it's the same as index()

... I'm not sure what the idea was here, but since these functions do
the same thing, let's only have index().
This commit is contained in:
Andreas Kling 2020-08-13 16:07:58 +02:00
parent fe19cf0ff2
commit 4088beb8eb
Notes: sideshowbarker 2024-07-19 03:40:21 +09:00
5 changed files with 4 additions and 15 deletions

View file

@ -288,7 +288,7 @@ void TreeView::paint_event(PaintEvent& event)
if (column_index != tree_column) {
Gfx::IntRect cell_rect(horizontal_padding() + x_offset, rect.y(), column_width, item_height());
auto cell_index = model.sibling(index.row(), column_index, index.parent());
auto cell_index = model.index(index.row(), column_index, index.parent());
if (auto* delegate = column_data(column_index).cell_painting_delegate.ptr()) {
delegate->paint(painter, cell_rect, palette(), model, cell_index);