mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-09-09 17:46:07 -05:00
deck editor autoselection
This commit is contained in:
@@ -268,6 +268,9 @@ void WndDeckEditor::updateCardInfoRight(const QModelIndex ¤t, const QModel
|
||||
void WndDeckEditor::updateSearch(const QString &search)
|
||||
{
|
||||
databaseDisplayModel->setCardNameBeginning(search);
|
||||
QModelIndexList sel = databaseView->selectionModel()->selectedRows();
|
||||
if (sel.isEmpty() && databaseDisplayModel->rowCount())
|
||||
databaseView->selectionModel()->setCurrentIndex(databaseDisplayModel->index(0, 0), QItemSelectionModel::SelectCurrent | QItemSelectionModel::Rows);
|
||||
}
|
||||
|
||||
bool WndDeckEditor::confirmClose()
|
||||
|
||||
Reference in New Issue
Block a user