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

Commit 89f90702 authored by Tom Ouyang's avatar Tom Ouyang
Browse files

Do not learn from cursor corrections when autocorrection is disabled.

Bug: 20681528
Change-Id: I80e7095b70a151f3ccc36856d7e0837613a35972
parent 459b4f35
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -398,9 +398,8 @@ public final class InputLogic {
            if (!TextUtils.isEmpty(mWordBeingCorrectedByCursor)) {
                final int timeStampInSeconds = (int)TimeUnit.MILLISECONDS.toSeconds(
                        System.currentTimeMillis());
                mDictionaryFacilitator.addToUserHistory(mWordBeingCorrectedByCursor, false,
                        NgramContext.EMPTY_PREV_WORDS_INFO, timeStampInSeconds,
                        settingsValues.mBlockPotentiallyOffensive);
                performAdditionToUserHistoryDictionary(settingsValues, mWordBeingCorrectedByCursor,
                        NgramContext.EMPTY_PREV_WORDS_INFO);
            }
        } else {
            // resetEntireInputState calls resetCachesUponCursorMove, but forcing the