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

Commit f9a9d504 authored by Danesh M's avatar Danesh M Committed by Gerrit Code Review
Browse files

InputMethodManager : Move registration to systemReady

Move registration to systemReady() so that CMHardware
is in a ready state for us to start interacting with.

CYNGNOS-1166

Change-Id: I37177c5e99bbe3850c82c6e1da36e9da80279456
parent cf083854
Loading
Loading
Loading
Loading
+10 −11
Original line number Diff line number Diff line
@@ -962,17 +962,6 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
            }
        }

        // Must happen before registerContentObserverLocked
        mCMHardware = CMHardwareManager.getInstance(mContext);

        synchronized (mMethodMap) {
            mSettingsObserver.registerContentObserverLocked(userId);
            updateFromSettingsLocked(true);
        }

        updateTouchHovering();
        updateTouchSensitivity();

        // IMMS wants to receive Intent.ACTION_LOCALE_CHANGED in order to update the current IME
        // according to the new system locale.
        final IntentFilter filter = new IntentFilter();
@@ -1136,6 +1125,16 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
            }
            if (!mSystemReady) {
                mSystemReady = true;
                // Must happen before registerContentObserverLocked
                mCMHardware = CMHardwareManager.getInstance(mContext);

                mSettingsObserver.registerContentObserverLocked(
                        mSettings.getCurrentUserId());
                updateFromSettingsLocked(true);

                updateTouchHovering();
                updateTouchSensitivity();

                mKeyguardManager =
                        (KeyguardManager) mContext.getSystemService(Context.KEYGUARD_SERVICE);
                mNotificationManager = (NotificationManager)