Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ab4a6604 authored by Mohammadinamul Sheik's avatar Mohammadinamul Sheik Committed by Android Git Automerger
Browse files

am 8f116d7c: Merge "Invoke onWordCommitUserTyped on startInput() with non empty wordcomposer"

* commit '8f116d7c':
  Invoke onWordCommitUserTyped on startInput() with non empty wordcomposer
parents b47ac5bb 8f116d7c
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -145,6 +145,13 @@ public final class InputLogic {
     */
    public void startInput(final String combiningSpec, final SettingsValues settingsValues) {
        mEnteredText = null;
        if (!mWordComposer.getTypedWord().isEmpty()) {
            // For messaging apps that offer send button, the IME does not get the opportunity
            // to capture the last word. This block should capture those uncommitted words.
            // The timestamp at which it is captured is not accurate but close enough.
            StatsUtils.onWordCommitUserTyped(
                    mWordComposer.getTypedWord(), mWordComposer.isBatchMode());
        }
        mWordComposer.restartCombining(combiningSpec);
        resetComposingState(true /* alsoResetLastComposedWord */);
        mDeleteCount = 0;