diff options
author | 2012-05-24 12:11:02 +0900 | |
---|---|---|
committer | 2012-05-24 12:11:02 +0900 | |
commit | c54d558e2e70bdfb2c1078cae7b88440d421dc67 (patch) | |
tree | e61367d03783373411981ff3ad2432fbf1cd927a /java/src/com/android/inputmethod/latin/LastComposedWord.java | |
parent | a0ac31fcaa01c21592a6e7af243c14dada65cf3e (diff) | |
download | latinime-c54d558e2e70bdfb2c1078cae7b88440d421dc67.tar.gz latinime-c54d558e2e70bdfb2c1078cae7b88440d421dc67.tar.xz latinime-c54d558e2e70bdfb2c1078cae7b88440d421dc67.zip |
Cancel adding user history bigram when autocorrection is cancelled
Bug: 6465474
Change-Id: Ifbfe0ddc2ce5fab070939ede3db7bf03a8535a45
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LastComposedWord.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/LastComposedWord.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/LastComposedWord.java b/java/src/com/android/inputmethod/latin/LastComposedWord.java index af0ef4b37..4e1f5fe92 100644 --- a/java/src/com/android/inputmethod/latin/LastComposedWord.java +++ b/java/src/com/android/inputmethod/latin/LastComposedWord.java @@ -46,17 +46,18 @@ public class LastComposedWord { public final String mTypedWord; public final String mCommittedWord; public final int mSeparatorCode; + public final CharSequence mPrevWord; private boolean mActive; public static final LastComposedWord NOT_A_COMPOSED_WORD = - new LastComposedWord(null, null, null, "", "", NOT_A_SEPARATOR); + new LastComposedWord(null, null, null, "", "", NOT_A_SEPARATOR, null); // Warning: this is using the passed objects as is and fully expects them to be // immutable. Do not fiddle with their contents after you passed them to this constructor. public LastComposedWord(final int[] primaryKeyCodes, final int[] xCoordinates, final int[] yCoordinates, final String typedWord, final String committedWord, - final int separatorCode) { + final int separatorCode, final CharSequence prevWord) { mPrimaryKeyCodes = primaryKeyCodes; mXCoordinates = xCoordinates; mYCoordinates = yCoordinates; @@ -64,6 +65,7 @@ public class LastComposedWord { mCommittedWord = committedWord; mSeparatorCode = separatorCode; mActive = true; + mPrevWord = prevWord; } public void deactivate() { |