Skip to content

Commit

Permalink
use QModelIndex instead
Browse files Browse the repository at this point in the history
  • Loading branch information
r3yc0n1c committed Apr 11, 2024
1 parent ece87c2 commit 91f64a7
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/dialogs/VersionInfoDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,9 @@ void VersionInfoDialog::clearSelectionOnClose()
ui->rightTreeWidget->clearSelection();

// remove default "current" item selection after dialog close
auto model = ui->leftTreeWidget->model();
ui->leftTreeWidget->setCurrentIndex(model->index(-1, -1));
model = ui->rightTreeWidget->model();
ui->leftTreeWidget->setCurrentIndex(model->index(-1, -1));
QModelIndex defaultIndex;
ui->leftTreeWidget->setCurrentIndex(defaultIndex);
ui->rightTreeWidget->setCurrentIndex(defaultIndex);
}

void VersionInfoDialog::CopyTreeWidgetSelection(QTreeWidget *t)
Expand Down

0 comments on commit 91f64a7

Please sign in to comment.