Merge "Change the first character check in bigram dictionary to be case insensitive."

main
Tom Ouyang 2012-03-26 02:17:12 -07:00 committed by Android (Google) Code Review
commit 94a2ac68e6
1 changed files with 2 additions and 1 deletions

View File

@ -151,8 +151,9 @@ bool BigramDictionary::checkFirstCharacter(unsigned short *word) {
int *inputCodes = mInputCodes;
int maxAlt = MAX_ALTERNATIVES;
const unsigned short firstBaseChar = toBaseLowerCase(*word);
while (maxAlt > 0) {
if ((unsigned int) *inputCodes == (unsigned int) *word) {
if (toBaseLowerCase(*inputCodes) == firstBaseChar) {
return true;
}
inputCodes++;