Merge pull request #15492 from vigreco/select-tree-root

Select root node if search_box is empty in create_dialog
This commit is contained in:
Rémi Verschelde 2018-02-14 17:04:08 +01:00 committed by GitHub
commit 1e4b3ddfbf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -316,6 +316,10 @@ void CreateDialog::_update_search() {
}
}
if (search_box->get_text() == "") {
to_select = root;
}
if (to_select) {
to_select->select(0);
search_options->scroll_to_item(to_select);