From 06f586e89047c3f2f7b33c518acb7e8166fd0f39 Mon Sep 17 00:00:00 2001 From: Robert Yevdokimov Date: Thu, 4 Jan 2024 18:07:31 -0500 Subject: [PATCH] Allow ui_cancel to unselect all nodes in 2D, matching 3D behavior --- editor/plugins/canvas_item_editor_plugin.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp index 3676d1165af..31eecd9db72 100644 --- a/editor/plugins/canvas_item_editor_plugin.cpp +++ b/editor/plugins/canvas_item_editor_plugin.cpp @@ -2463,7 +2463,7 @@ bool CanvasItemEditor::_gui_input_select(const Ref &p_event) { } } - if (k.is_valid() && k->is_action_pressed(SNAME("ui_cancel"), false, true) && drag_type == DRAG_NONE && tool == TOOL_SELECT) { + if (k.is_valid() && k->is_action_pressed(SNAME("ui_cancel"), false, true) && drag_type == DRAG_NONE) { // Unselect everything editor_selection->clear(); viewport->queue_redraw();