I'm aware of this link: No OnKeyDown event for Return key on Delphi Android 10.3.3
which @blong had given a solution in 10.3.3
Looking at the code in 10.4.1, it seems that Embarcadero had removed the ELSE block as @blong had suggested. Looks like it's possible Embarcadero monitors this forum for fixed posted by users.
EDITED: this code is from Delphi's source code in FMXEditText.java (detailed source code not included as it's Embarcadero's source).
@Override
public void onEditorAction(int actionCode) {
// Disable default processing logic of ReturnKey.
if (actionCode == EditorInfo.IME_ACTION_DONE) {
...
...
}
// Delegate handle Editor action to FMX side.
for (FMXTextListener listener : listeners) {
listener.onEditorAction(actionCode);
}
}
However, the OnKeyDown still does not work in Delphi 10.4.1
Please advise how I can get OnKeyDown to work for a TEdit in 10.4.1. iOS works fine, so it's unimaginable why would Android version be so restrictive.
Any gurus out here who knows how to over-ride the Android system?
Thanks.