Merge pull request #90835 from bruvzg/input_dup

Fix input map shortcuts incorrectly edited on cancel.
This commit is contained in:
Rémi Verschelde 2024-04-18 12:25:02 +02:00
commit 1ebdacb4b0
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -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) { void InputEventConfigurationDialog::popup_and_configure(const Ref<InputEvent> &p_event, const String &p_current_action_name) {
if (p_event.is_valid()) { if (p_event.is_valid()) {
_set_event(p_event->duplicate(), p_event); _set_event(p_event->duplicate(), p_event->duplicate());
} else { } else {
// Clear Event // Clear Event
_set_event(Ref<InputEvent>(), Ref<InputEvent>()); _set_event(Ref<InputEvent>(), Ref<InputEvent>());