Anki-Android
Anki-Android copied to clipboard
In Text Field with one line, "Enter" on physical keyboard should validate the action
I'll first give you the example that I currently care about, while I test AnkiDroid in the emulator, then the general request.
# Examples
Create Deck
How to reproduce:
- open ankidroid
- tap on plus > Create deck
- on a physical keyboard, type "foo" and press enter
Expected result:
- The new deck is created
Actual result:
- The focus goes on the cancel button
Automatic backup
- Open the settings
- backup
- minutes between automatic backups
- tap 31, enter
Expected
- you'll see the number 31, and validated
Actual:
- all keyboard interaction are ignored
General case
More generally, we should look at all text field/text input that has either:
- IncrementNumberRangePreferenceCompat
- any TextInputEditTExt with
android:maxLines="1"
. That is, dialog_tts_voices dialog_tts_voices_voice and dialog_generic_text_input.xml (I admit I don't know TTS and don't know which dialog it corresponds to)
Note to contributors
If you want to be assigned this issue, please don't hesitate to tell us that you'll only work on one single part of the issue. There seems to be a dozen of part of the code to correct. I don't know how many part can be corrected at once, and how many requires distinct code change. Also, don't hesitate to do small commits/PR, that solve only one part of the problem, so that we can iterate quickly