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

Commit 4fde56b8 authored by Jean Chalard's avatar Jean Chalard
Browse files

Fix a bug where spaces would be forgotten

Bug: 6785706
Change-Id: Ic7bf242ef058d116b986d47ad197b6d2802e2342
parent 362ea3ca
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1799,6 +1799,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
            return;
        }

        mConnection.beginBatchEdit();
        if (SPACE_STATE_PHANTOM == mSpaceState && suggestion.length() > 0) {
            int firstChar = Character.codePointAt(suggestion, 0);
            if ((!mCurrentSettings.isWeakSpaceStripper(firstChar))
@@ -1816,7 +1817,6 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
            mKeyboardSwitcher.updateShiftState();
            resetComposingState(true /* alsoResetLastComposedWord */);
            final CompletionInfo completionInfo = mApplicationSpecifiedCompletions[index];
            mConnection.beginBatchEdit();
            mConnection.commitCompletion(completionInfo);
            mConnection.endBatchEdit();
            if (ProductionFlag.IS_EXPERIMENTAL) {
@@ -1837,6 +1837,7 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen
        mExpectingUpdateSelection = true;
        commitChosenWord(suggestion, LastComposedWord.COMMIT_TYPE_MANUAL_PICK,
                LastComposedWord.NOT_A_SEPARATOR);
        mConnection.endBatchEdit();
        // Don't allow cancellation of manual pick
        mLastComposedWord.deactivate();
        mSpaceState = SPACE_STATE_PHANTOM;