Explorar o código

Merge pull request #37839 from MrRevington/3.2-_input_focus_check

FIX CodeTextEditor not respecting focus in _input
Rémi Verschelde %!s(int64=5) %!d(string=hai) anos
pai
achega
19dc5c42d8
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      editor/code_editor.cpp

+ 1 - 1
editor/code_editor.cpp

@@ -657,7 +657,7 @@ FindReplaceBar::FindReplaceBar() {
 // be handled too late if they weren't handled here.
 void CodeTextEditor::_input(const Ref<InputEvent> &event) {
 	const Ref<InputEventKey> key_event = event;
-	if (!key_event.is_valid() || !key_event->is_pressed()) {
+	if (!key_event.is_valid() || !key_event->is_pressed() || !text_editor->has_focus()) {
 		return;
 	}