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

Commit 195fc85d authored by Schneider Victor-tulias's avatar Schneider Victor-tulias Committed by Android (Google) Code Review
Browse files

Merge "Add error detection for missing recent tasks list in SystemUiProxy" into main

parents b604e71f c6d3ea67
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@ import static android.app.ActivityManager.RECENT_IGNORE_UNAVAILABLE;

import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
import static com.android.launcher3.util.Executors.UI_HELPER_EXECUTOR;
import static com.android.quickstep.util.ActiveGestureErrorDetector.GestureEvent.RECENT_TASKS_MISSING;
import static com.android.quickstep.util.LogUtils.splitFailureMessage;

import android.app.ActivityManager;
@@ -63,6 +64,7 @@ import com.android.internal.view.AppearanceRegion;
import com.android.launcher3.util.MainThreadInitializedObject;
import com.android.launcher3.util.Preconditions;
import com.android.launcher3.util.SplitConfigurationOptions;
import com.android.quickstep.util.ActiveGestureLog;
import com.android.quickstep.util.AssistUtils;
import com.android.systemui.shared.recents.ISystemUiProxy;
import com.android.systemui.shared.recents.model.ThumbnailData;
@@ -1372,6 +1374,7 @@ public class SystemUiProxy implements ISystemUiProxy {
    public boolean startRecentsActivity(Intent intent, ActivityOptions options,
            RecentsAnimationListener listener) {
        if (mRecentTasks == null) {
            ActiveGestureLog.INSTANCE.trackEvent(RECENT_TASKS_MISSING);
            return false;
        }
        final IRecentsAnimationRunner runner = new IRecentsAnimationRunner.Stub() {
+9 −1
Original line number Diff line number Diff line
@@ -37,7 +37,7 @@ public class ActiveGestureErrorDetector {
        START_RECENTS_ANIMATION, FINISH_RECENTS_ANIMATION, CANCEL_RECENTS_ANIMATION,
        SET_ON_PAGE_TRANSITION_END_CALLBACK, CANCEL_CURRENT_ANIMATION, CLEANUP_SCREENSHOT,
        SCROLLER_ANIMATION_ABORTED, TASK_APPEARED, EXPECTING_TASK_APPEARED,
        FLAG_USING_OTHER_ACTIVITY_INPUT_CONSUMER, LAUNCHER_DESTROYED,
        FLAG_USING_OTHER_ACTIVITY_INPUT_CONSUMER, LAUNCHER_DESTROYED, RECENT_TASKS_MISSING,

        /**
         * These GestureEvents are specifically associated to state flags that get set in
@@ -218,6 +218,14 @@ public class ActiveGestureErrorDetector {
                                    + "set before/without startRecentsAnimation.",
                            writer);
                    break;
                case RECENT_TASKS_MISSING:
                    errorDetected |= printErrorIfTrue(
                            true,
                            prefix,
                            /* errorMessage= */ "SystemUiProxy.mRecentTasks missing,"
                                    + " couldn't start the recents activity",
                            writer);
                    break;
                case MOTION_DOWN:
                case SET_END_TARGET:
                case SET_END_TARGET_HOME: