SearchDialog: Select first item in the lit, if search_list has at least one item
This commit is contained in:
YuSanka 2020-06-26 13:45:54 +02:00
parent 990bfc0d76
commit 53b6c93ceb

View file

@ -617,8 +617,9 @@ void SearchDialog::update_list()
for (const FoundOption& item : filters)
search_list_model->Prepend(item.label);
// select first item
search_list->Select(search_list_model->GetItem(0));
// select first item, if search_list
if (search_list_model->GetCount() > 0)
search_list->Select(search_list_model->GetItem(0));
prevent_list_events = false;
}