Jelajahi Sumber

Merge pull request #90835 from bruvzg/input_dup

Fix input map shortcuts incorrectly edited on cancel.
Rémi Verschelde 1 tahun lalu
induk
melakukan
1ebdacb4b0
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      editor/input_event_configuration_dialog.cpp

+ 1 - 1
editor/input_event_configuration_dialog.cpp

@@ -587,7 +587,7 @@ void InputEventConfigurationDialog::_notification(int p_what) {
 
 void InputEventConfigurationDialog::popup_and_configure(const Ref<InputEvent> &p_event, const String &p_current_action_name) {
 	if (p_event.is_valid()) {
-		_set_event(p_event->duplicate(), p_event);
+		_set_event(p_event->duplicate(), p_event->duplicate());
 	} else {
 		// Clear Event
 		_set_event(Ref<InputEvent>(), Ref<InputEvent>());