I see id == EditorInfo.IME_NULL
used regularly in places which are supposed to match "Done" or "Enter" in addition to another condition such as the enter key or an IME action but I cannot find any explanation as to what exactly it is.
This code is preset everywhere when dealing with the "Enter" button on the soft keyboard.
The Andriod Documentation is not explicit, but IME_NULL is the generic key for "Enter"
This is also relevant in relation to IME's (Input Method Editor).
It's wrong, but it's been copied and pasted quite a bit and is probably more prevalent than code that actually uses the correct constant here.
Per the documentation, IME_NULL
is supposed to represent the value of the imeOptions
field when no option flags are set.
The correct constant in this case is IME_ACTION_UNSPECIFIED
, which indicates that the user has instructed your app to take some action, but the exact action is not defined.
The two are interchangeable because they have the same integer value (zero).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With