Browse Source

CreateDialog: select root if search exactly match

(cherry picked from commit 9fb90d7aea70a645bcc3987387f4cd048b8413fe)
Poommetee Ketson 8 years ago
parent
commit
76955cc187
1 changed files with 1 additions and 1 deletions
  1. 1 1
      editor/create_dialog.cpp

+ 1 - 1
editor/create_dialog.cpp

@@ -222,7 +222,7 @@ void CreateDialog::_update_search() {
 	}
 	}
 
 
 	List<StringName>::Element *I = type_list.front();
 	List<StringName>::Element *I = type_list.front();
-	TreeItem *to_select = NULL;
+	TreeItem *to_select = search_box->get_text() == base_type ? root : NULL;
 
 
 	for (; I; I = I->next()) {
 	for (; I; I = I->next()) {