Explorar o código

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

Select root node if search_box is empty in create_dialog
Rémi Verschelde %!s(int64=7) %!d(string=hai) anos
pai
achega
1e4b3ddfbf
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      editor/create_dialog.cpp

+ 4 - 0
editor/create_dialog.cpp

@@ -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);