Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 988af086 authored by Ken Wakasa's avatar Ken Wakasa Committed by Android Git Automerger
Browse files

am 943f6d0b: Merge "Turn off the spell checker when the spell checker is...

am 943f6d0b: Merge "Turn off the spell checker when the spell checker is disabled in the settings" into ics-mr1

* commit '943f6d0b':
  Turn off the spell checker when the spell checker is disabled in the settings
parents a25b1a27 943f6d0b
Loading
Loading
Loading
Loading
+8 −3
Original line number Diff line number Diff line
@@ -90,9 +90,14 @@ public class SpellChecker implements SpellCheckerSessionListener {
    private void setLocale(Locale locale) {
        final TextServicesManager textServicesManager = (TextServicesManager)
                mTextView.getContext().getSystemService(Context.TEXT_SERVICES_MANAGER_SERVICE);
        if (!textServicesManager.isSpellCheckerEnabled()) {
            mSpellCheckerSession = null;
        } else {
            mSpellCheckerSession = textServicesManager.newSpellCheckerSession(
                    null /* Bundle not currently used by the textServicesManager */,
                locale, this, false /* means any available languages from current spell checker */);
                    locale, this,
                    false /* means any available languages from current spell checker */);
        }
        mCurrentLocale = locale;

        // Restore SpellCheckSpans in pool