From 5971a0a0bbbb671bb5b7d5cc7829ddf169c0cc7a Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Thu, 26 Jan 2012 17:43:10 +0900 Subject: [PATCH] Remove a useless member (A8) It turns out this can be removed entirely. Change-Id: I6f23703cef1666311989a825285317eef696487f --- .../src/com/android/inputmethod/latin/LastComposedWord.java | 6 ++---- java/src/com/android/inputmethod/latin/WordComposer.java | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/java/src/com/android/inputmethod/latin/LastComposedWord.java b/java/src/com/android/inputmethod/latin/LastComposedWord.java index 767c3a7da..0c8c88f50 100644 --- a/java/src/com/android/inputmethod/latin/LastComposedWord.java +++ b/java/src/com/android/inputmethod/latin/LastComposedWord.java @@ -40,7 +40,6 @@ public class LastComposedWord { // an auto-correction. public static final int COMMIT_TYPE_CANCEL_AUTO_CORRECT = 3; - public final int mType; public final ArrayList mCodes; public final int[] mXCoordinates; public final int[] mYCoordinates; @@ -50,11 +49,10 @@ public class LastComposedWord { private boolean mActive; public static final LastComposedWord NOT_A_COMPOSED_WORD = - new LastComposedWord(COMMIT_TYPE_USER_TYPED_WORD, null, null, null, "", ""); + new LastComposedWord(null, null, null, "", ""); - public LastComposedWord(final int type, final ArrayList codes, final int[] xCoordinates, + public LastComposedWord(final ArrayList codes, final int[] xCoordinates, final int[] yCoordinates, final String typedWord, final String autoCorrection) { - mType = type; mCodes = codes; mXCoordinates = xCoordinates; mYCoordinates = yCoordinates; diff --git a/java/src/com/android/inputmethod/latin/WordComposer.java b/java/src/com/android/inputmethod/latin/WordComposer.java index 12b009662..b96b0842a 100644 --- a/java/src/com/android/inputmethod/latin/WordComposer.java +++ b/java/src/com/android/inputmethod/latin/WordComposer.java @@ -309,7 +309,7 @@ public class WordComposer { // LastComposedWord#didAutoCorrectToAnotherWord with #equals(). It would be marginally // cleaner to do it here, but it would be slower (since we would #equals() for each commit, // instead of only on cancel), and ultimately we want to figure it out even earlier anyway. - final LastComposedWord lastComposedWord = new LastComposedWord(type, mCodes, + final LastComposedWord lastComposedWord = new LastComposedWord(mCodes, mXCoordinates, mYCoordinates, mTypedWord.toString(), (type != LastComposedWord.COMMIT_TYPE_DECIDED_WORD) || (null == mAutoCorrection) ? null : mAutoCorrection.toString());