diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2021-07-06 23:46:21 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-06 23:46:21 +0200 |
commit | 5d7c23dcc66758000544d7ef841e7db11ae51c4e (patch) | |
tree | 60fb1649ba88d0fd5b02e4525903ec4abe72867e /platform/android/java/lib/src/org | |
parent | 2aa1915617b6918ec6ae3044ccb67c70c31c4f04 (diff) | |
parent | 1856f163784005d2b4ed74e5597f934b0b63ae81 (diff) |
Merge pull request #50220 from madmiraal/fix-50125
Queue the calls to GodotLib.key when Android virtual done is pressed
Diffstat (limited to 'platform/android/java/lib/src/org')
-rw-r--r-- | platform/android/java/lib/src/org/godotengine/godot/input/GodotTextInputWrapper.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/platform/android/java/lib/src/org/godotengine/godot/input/GodotTextInputWrapper.java b/platform/android/java/lib/src/org/godotengine/godot/input/GodotTextInputWrapper.java index f7a3380a93..020870a110 100644 --- a/platform/android/java/lib/src/org/godotengine/godot/input/GodotTextInputWrapper.java +++ b/platform/android/java/lib/src/org/godotengine/godot/input/GodotTextInputWrapper.java @@ -144,9 +144,10 @@ public class GodotTextInputWrapper implements TextWatcher, OnEditorActionListene if (pActionID == EditorInfo.IME_ACTION_DONE) { // Enter key has been pressed - GodotLib.key(KeyEvent.KEYCODE_ENTER, KeyEvent.KEYCODE_ENTER, 0, true); - GodotLib.key(KeyEvent.KEYCODE_ENTER, KeyEvent.KEYCODE_ENTER, 0, false); - + mRenderView.queueOnRenderThread(() -> { + GodotLib.key(KeyEvent.KEYCODE_ENTER, KeyEvent.KEYCODE_ENTER, 0, true); + GodotLib.key(KeyEvent.KEYCODE_ENTER, KeyEvent.KEYCODE_ENTER, 0, false); + }); mRenderView.getView().requestFocus(); return true; } |