fix some keys triggering their actions twice in GridMap

This commit is contained in:
Geoffroy Warin 2023-09-11 03:03:43 +02:00
parent fc99492d30
commit 5f3cbcb55d

View File

@ -749,6 +749,7 @@ EditorPlugin::AfterGUIInput GridMapEditor::forward_spatial_input_event(Camera3D
for (int i = 0; i < options->get_popup()->get_item_count(); ++i) {
const Ref<Shortcut> &shortcut = options->get_popup()->get_item_shortcut(i);
if (shortcut.is_valid() && shortcut->matches_event(p_event)) {
accept_event();
_menu_option(options->get_popup()->get_item_id(i));
return EditorPlugin::AFTER_GUI_INPUT_STOP;
}