Merge "Use user's settings for the spell check language instead of the system locale"

This commit is contained in:
satok
2011-09-30 01:52:40 -07:00
committed by Android (Google) Code Review
2 changed files with 5 additions and 2 deletions

View File

@@ -61,7 +61,9 @@ public class SpellChecker implements SpellCheckerSessionListener {
final TextServicesManager textServicesManager = (TextServicesManager) textView.getContext(). final TextServicesManager textServicesManager = (TextServicesManager) textView.getContext().
getSystemService(Context.TEXT_SERVICES_MANAGER_SERVICE); getSystemService(Context.TEXT_SERVICES_MANAGER_SERVICE);
mSpellCheckerSession = textServicesManager.newSpellCheckerSession( mSpellCheckerSession = textServicesManager.newSpellCheckerSession(
null /* not currently used by the textServicesManager */, Locale.getDefault(), null /* not currently used by the textServicesManager */,
null /* null locale means use the languages defined in Settings
if referToSpellCheckerLanguageSettings is true */,
this, true /* means use the languages defined in Settings */); this, true /* means use the languages defined in Settings */);
mCookie = hashCode(); mCookie = hashCode();

View File

@@ -238,7 +238,8 @@ public class TextServicesManagerService extends ITextServicesManager.Stub {
} }
} else if (scs.hashCode() == hashCode) { } else if (scs.hashCode() == hashCode) {
if (DBG) { if (DBG) {
Slog.w(TAG, "Return subtype " + scs.hashCode()); Slog.w(TAG, "Return subtype " + scs.hashCode() + ", input= " + locale
+ ", " + scs.getLocale());
} }
return scs; return scs;
} }