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

Commit 49d6bb66 authored by Winson Chung's avatar Winson Chung Committed by Android (Google) Code Review
Browse files

Merge "Add some logging to track launcher service and gesture monitor lifecycle" into sc-dev

parents 3ee18bf5 aea7a32b
Loading
Loading
Loading
Loading
+10 −1
Original line number Diff line number Diff line
@@ -149,6 +149,8 @@ public class TouchInteractionService extends Service implements PluginListener<O

        @BinderThread
        public void onInitialize(Bundle bundle) {
            Log.d(TAG + " b/182478748", "TouchInteractionService.onInitialize: user="
                    + getUserId());
            ISystemUiProxy proxy = ISystemUiProxy.Stub.asInterface(
                    bundle.getBinder(KEY_EXTRA_SYSUI_PROXY));
            IPip pip = IPip.Stub.asInterface(bundle.getBinder(KEY_EXTRA_SHELL_PIP));
@@ -310,6 +312,8 @@ public class TouchInteractionService extends Service implements PluginListener<O
    }

    private void disposeEventHandlers() {
        Log.d(TAG + " b/182478748", "TouchInteractionService.disposeEventHandlers: user="
                + getUserId());
        if (mInputEventReceiver != null) {
            mInputEventReceiver.dispose();
            mInputEventReceiver = null;
@@ -321,6 +325,8 @@ public class TouchInteractionService extends Service implements PluginListener<O
    }

    private void initInputMonitor() {
        Log.d(TAG + " b/182478748", "TouchInteractionService.initInputMonitor: user="
                + getUserId());
        disposeEventHandlers();

        if (TestProtocol.sDebugTracing) {
@@ -329,9 +335,11 @@ public class TouchInteractionService extends Service implements PluginListener<O
        }

        if (mDeviceState.isButtonNavMode()) {
            Log.d(TAG + " b/182478748", "isButtonNav: user=" + getUserId());
            return;
        }

        Log.d(TAG + " b/182478748", "create swipe-up input monitor: user=" + getUserId());
        mInputMonitorCompat = new InputMonitorCompat("swipe-up", mDeviceState.getDisplayId());
        mInputEventReceiver = mInputMonitorCompat.getInputReceiver(Looper.getMainLooper(),
                mMainChoreographer, this::onInputEvent);
@@ -448,6 +456,7 @@ public class TouchInteractionService extends Service implements PluginListener<O

    @Override
    public void onDestroy() {
        Log.d(TAG, "Touch service destroyed: user=" + getUserId());
        sIsInitialized = false;
        if (mDeviceState.isUserUnlocked()) {
            mInputConsumer.unregisterInputConsumer();
@@ -469,7 +478,7 @@ public class TouchInteractionService extends Service implements PluginListener<O

    @Override
    public IBinder onBind(Intent intent) {
        Log.d(TAG, "Touch service connected");
        Log.d(TAG, "Touch service connected: user=" + getUserId());
        return mMyBinder;
    }