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

Commit 10dff768 authored by Tadashi G. Takaoka's avatar Tadashi G. Takaoka
Browse files

Fix NPE introduced by I38b21d49

Bug: 5560766
Change-Id: Ic5eaebe0ef893c69ad90a777ebfa07807535a0e3
parent 15a01d72
Loading
Loading
Loading
Loading
+11 −8
Original line number Diff line number Diff line
@@ -245,18 +245,20 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
        private static final int MSG_SET_BIGRAM_PREDICTIONS = 7;
        private static final int MSG_PENDING_IMS_CALLBACK = 8;

        private final int mDelayBeforeFadeoutLanguageOnSpacebar;
        private final int mDelayUpdateSuggestions;
        private final int mDelayUpdateShiftState;
        private final int mDurationOfFadeoutLanguageOnSpacebar;
        private final float mFinalFadeoutFactorOfLanguageOnSpacebar;
        private final long mDoubleSpacesTurnIntoPeriodTimeout;
        private final long mIgnoreSpecialKeyTimeout;
        private int mDelayBeforeFadeoutLanguageOnSpacebar;
        private int mDelayUpdateSuggestions;
        private int mDelayUpdateShiftState;
        private int mDurationOfFadeoutLanguageOnSpacebar;
        private float mFinalFadeoutFactorOfLanguageOnSpacebar;
        private long mDoubleSpacesTurnIntoPeriodTimeout;
        private long mIgnoreSpecialKeyTimeout;

        public UIHandler(LatinIME outerInstance) {
            super(outerInstance);
        }

            final Resources res = outerInstance.getResources();
        public void onCreate() {
            final Resources res = getOuterInstance().getResources();
            mDelayBeforeFadeoutLanguageOnSpacebar = res.getInteger(
                    R.integer.config_delay_before_fadeout_language_on_spacebar);
            mDelayUpdateSuggestions =
@@ -497,6 +499,7 @@ public class LatinIME extends InputMethodServiceCompatWrapper implements Keyboar
        mSubtypeSwitcher = SubtypeSwitcher.getInstance();
        mKeyboardSwitcher = KeyboardSwitcher.getInstance();
        mVibrator = VibratorCompatWrapper.getInstance(this);
        mHandler.onCreate();
        DEBUG = LatinImeLogger.sDBG;

        final Resources res = getResources();