mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-06 16:45:03 +00:00
GAbstractView: Add function for adding all to selection
This commit is contained in:
committed by
Andreas Kling
parent
00596296c4
commit
7cf15bcb75
@@ -95,6 +95,18 @@ void GAbstractView::stop_editing()
|
||||
}
|
||||
}
|
||||
|
||||
void GAbstractView::select_all()
|
||||
{
|
||||
ASSERT(model());
|
||||
int rows = model()->row_count();
|
||||
int columns = model()->column_count();
|
||||
|
||||
for (int i = 0; i < rows; ++i) {
|
||||
for (int j = 0; j < columns; ++j)
|
||||
selection().add(model()->index(i, j));
|
||||
}
|
||||
}
|
||||
|
||||
void GAbstractView::activate(const GModelIndex& index)
|
||||
{
|
||||
if (on_activation)
|
||||
|
||||
Reference in New Issue
Block a user