| 562 | } |
| 563 | |
| 564 | void VersionPage::preselect(int row) |
| 565 | { |
| 566 | if(row < 0) |
| 567 | { |
| 568 | row = 0; |
| 569 | } |
| 570 | if(row >= m_profile->rowCount(QModelIndex())) |
| 571 | { |
| 572 | row = m_profile->rowCount(QModelIndex()) - 1; |
| 573 | } |
| 574 | if(row < 0) |
| 575 | { |
| 576 | return; |
| 577 | } |
| 578 | auto model_index = m_profile->index(row); |
| 579 | ui->packageView->selectionModel()->select(model_index, QItemSelectionModel::SelectCurrent | QItemSelectionModel::Rows); |
| 580 | updateButtons(row); |
| 581 | } |
| 582 | |
| 583 | void VersionPage::onGameUpdateError(QString error) |
| 584 | { |
nothing calls this directly
no test coverage detected