From 6a800b253f0ea329808b582033a0ec3fc240d692 Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Wed, 8 Feb 2012 11:50:34 +0900 Subject: [PATCH] Some more simplification Remove useless method calls, and ultimately remove useless method. Change-Id: I3f353b1b37460d5e9ceae5cb5dde3fff0da81c21 --- java/src/com/android/inputmethod/latin/LatinIME.java | 6 ++---- java/src/com/android/inputmethod/latin/SettingsValues.java | 4 ---- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 8b8c0242d..d53155224 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -2107,13 +2107,11 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar CharSequence toLeft = ic.getTextBeforeCursor(1, 0); CharSequence toRight = ic.getTextAfterCursor(1, 0); if (!TextUtils.isEmpty(toLeft) - && !mSettingsValues.isWordSeparator(toLeft.charAt(0)) - && !mSettingsValues.isSuggestedPunctuation(toLeft.charAt(0))) { + && !mSettingsValues.isWordSeparator(toLeft.charAt(0))) { return true; } if (!TextUtils.isEmpty(toRight) - && !mSettingsValues.isWordSeparator(toRight.charAt(0)) - && !mSettingsValues.isSuggestedPunctuation(toRight.charAt(0))) { + && !mSettingsValues.isWordSeparator(toRight.charAt(0))) { return true; } return false; diff --git a/java/src/com/android/inputmethod/latin/SettingsValues.java b/java/src/com/android/inputmethod/latin/SettingsValues.java index 589cb6f86..6b652313c 100644 --- a/java/src/com/android/inputmethod/latin/SettingsValues.java +++ b/java/src/com/android/inputmethod/latin/SettingsValues.java @@ -222,10 +222,6 @@ public class SettingsValues { res.getBoolean(R.bool.config_default_vibration_enabled)); } - public boolean isSuggestedPunctuation(int code) { - return mSuggestPuncs.contains(String.valueOf((char)code)); - } - public boolean isWordSeparator(int code) { return mWordSeparators.contains(String.valueOf((char)code)); }