From 6c4dbf92acc9ee60927b00c60fbce0588a559421 Mon Sep 17 00:00:00 2001 From: taigi100 Date: Tue, 15 Mar 2022 20:04:59 +0200 Subject: Update to only use select tool on button press It used to run the code twice, probably once on button press, once on button release. --- 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 d74499621d..d713e70251 100644 --- a/editor/plugins/canvas_item_editor_plugin.cpp +++ b/editor/plugins/canvas_item_editor_plugin.cpp @@ -2216,7 +2216,7 @@ bool CanvasItemEditor::_gui_input_select(const Ref &p_event) { Ref k = p_event; if (drag_type == DRAG_NONE) { - if (b.is_valid() && + if (b.is_valid() && b->is_pressed() && ((b->get_button_index() == MouseButton::RIGHT && b->is_alt_pressed() && tool == TOOL_SELECT) || (b->get_button_index() == MouseButton::LEFT && tool == TOOL_LIST_SELECT))) { // Popup the selection menu list -- cgit v1.2.3