From 1adcd57377a4364e0c5f28d7aa929ac98827eb9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dominik=20=27squ=40ll=27=20Jasi=C5=84ski?= Date: Sat, 8 Feb 2020 21:46:04 +0100 Subject: [PATCH] Allow using Enter key for replacing text in code editors (also Shift + Enter works backwards) Fixes issue #31762 --- editor/code_editor.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/editor/code_editor.cpp b/editor/code_editor.cpp index e05ace53daa..e785c527326 100644 --- a/editor/code_editor.cpp +++ b/editor/code_editor.cpp @@ -517,6 +517,11 @@ void FindReplaceBar::_replace_text_entered(const String &p_text) { if (selection_only->is_pressed() && text_edit->is_selection_active()) { _replace_all(); _hide_bar(); + } else if (Input::get_singleton()->is_key_pressed(KEY_SHIFT)) { + _replace(); + search_prev(); + } else { + _replace(); } }