Merge pull request #46079 from KoBeWi/the_selection

Select TreeItem if none is selected
This commit is contained in:
Rémi Verschelde 2021-02-16 09:56:34 +01:00 committed by GitHub
commit 866cad9767
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -3342,6 +3342,9 @@ void Tree::item_selected(int p_column, TreeItem *p_item) {
//emit_signal("multi_selected",p_item,p_column,true); - NO this is for TreeItem::select //emit_signal("multi_selected",p_item,p_column,true); - NO this is for TreeItem::select
selected_col = p_column; selected_col = p_column;
if (!selected_item) {
selected_item = p_item;
}
} else { } else {
select_single_item(p_item, root, p_column); select_single_item(p_item, root, p_column);
} }