Skip to content

Commit

Permalink
Fix autosend on Whatsapp
Browse files Browse the repository at this point in the history
  • Loading branch information
adgad committed Dec 28, 2021
1 parent 15f5d24 commit e49b051
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app/src/main/java/com/adgad/kboard/KCommands.java
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,10 @@ public void fr(int n, String parameter) {

//send
public void s(int n) {
if((inputEditor.imeOptions & EditorInfo.IME_MASK_ACTION) == EditorInfo.IME_ACTION_SEND) {
if((inputEditor.imeOptions & EditorInfo.IME_MASK_ACTION) == EditorInfo.IME_ACTION_SEND ) {
inputConnection.performEditorAction(EditorInfo.IME_ACTION_SEND);
// Whatsapp seems to now have IME_ACTION_DONE, but sending still works so do that instead
} else if((inputEditor.imeOptions & EditorInfo.IME_MASK_ACTION) == EditorInfo.IME_ACTION_DONE ) {
inputConnection.performEditorAction(EditorInfo.IME_ACTION_SEND);
}
}
Expand Down

0 comments on commit e49b051

Please sign in to comment.