Make handling of rename line-edit popups more robust

This commit is contained in:
Pedro J. Estébanez
2024-05-01 13:39:54 +02:00
parent 259d576f6e
commit eb2bd41fb8
4 changed files with 20 additions and 6 deletions

View File

@@ -138,9 +138,7 @@ String FileSystemList::get_edit_text() {
}
void FileSystemList::_text_editor_popup_modal_close() {
if (Input::get_singleton()->is_key_pressed(Key::ESCAPE) ||
Input::get_singleton()->is_key_pressed(Key::KP_ENTER) ||
Input::get_singleton()->is_key_pressed(Key::ENTER)) {
if (popup_editor->get_hide_reason() == Popup::HIDE_REASON_CANCELED) {
return;
}