Skip to content

Commit

Permalink
Add foreign validation warning for rename actions.
Browse files Browse the repository at this point in the history
  • Loading branch information
SaracenOne committed Oct 26, 2023
1 parent 06d5189 commit 5deff6c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions editor/scene_tree_dock.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,6 +378,9 @@ void SceneTreeDock::_tool_selected(int p_tool, bool p_confirm_override) {
break;
}
if (editor_selection->get_selected_node_list().size() > 1) {
if (!_validate_no_foreign()) {
break;
}
rename_dialog->popup_centered();
}
} break;
Expand All @@ -388,6 +391,9 @@ void SceneTreeDock::_tool_selected(int p_tool, bool p_confirm_override) {
}
Tree *tree = scene_tree->get_scene_tree();
if (tree->is_anything_selected()) {
if (!_validate_no_foreign()) {
break;
}
tree->grab_focus();
tree->edit_selected();
}
Expand Down

0 comments on commit 5deff6c

Please sign in to comment.