From 0a7944653105f257d99e9db2d90b2bfc932ee765 Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Tue, 26 Jun 2012 16:01:09 +0900 Subject: Remove a meaningless separation (A18) Change-Id: I267177044c7d7b0d9119839a11057b2bbf41f75f --- .../inputmethod/latin/spellcheck/AndroidSpellCheckerService.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java') diff --git a/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java b/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java index 3bf18c520..5f4d66091 100644 --- a/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java +++ b/java/src/com/android/inputmethod/latin/spellcheck/AndroidSpellCheckerService.java @@ -238,8 +238,8 @@ public class AndroidSpellCheckerService extends SpellCheckerService mScores = new int[mMaxLength]; } - synchronized public boolean oldAddWord(char[] word, int[] spaceIndices, int wordOffset, - int wordLength, int score, int dicTypeId /* unused */, int dataType) { + synchronized public boolean addWord(char[] word, int[] spaceIndices, int wordOffset, + int wordLength, int score) { final int positionIndex = Arrays.binarySearch(mScores, 0, mLength, score); // binarySearch returns the index if the element exists, and - - 1 // if it doesn't. See documentation for binarySearch. @@ -784,9 +784,8 @@ public class AndroidSpellCheckerService extends SpellCheckerService composer, prevWord, dictInfo.mProximityInfo); for (final SuggestedWordInfo suggestion : suggestions) { final String suggestionStr = suggestion.mWord.toString(); - suggestionsGatherer.oldAddWord(suggestionStr.toCharArray(), null, 0, - suggestionStr.length(), suggestion.mScore, 0 /* ignored */, - Dictionary.UNIGRAM); + suggestionsGatherer.addWord(suggestionStr.toCharArray(), null, 0, + suggestionStr.length(), suggestion.mScore); } isInDict = dictInfo.mDictionary.isValidWord(text); if (!isInDict && CAPITALIZE_NONE != capitalizeType) { -- cgit v1.2.3-83-g751a