1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00

Fix crash when moving an action into itself in the Input Map editor

This commit is contained in:
Michael Alexsander Silva Dias
2019-09-27 22:12:35 -03:00
parent 7a67ae01a4
commit 4e9df13a40

View File

@@ -1078,7 +1078,7 @@ bool ProjectSettingsEditor::can_drop_data_fw(const Point2 &p_point, const Varian
TreeItem *selected = input_editor->get_selected(); TreeItem *selected = input_editor->get_selected();
TreeItem *item = input_editor->get_item_at_position(p_point); TreeItem *item = input_editor->get_item_at_position(p_point);
if (!selected || !item || item->get_parent() == selected) if (!selected || !item || item == selected || item->get_parent() == selected)
return false; return false;
return true; return true;