Loading quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java +11 −0 Original line number Diff line number Diff line Loading @@ -334,6 +334,12 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, return ActiveGestureErrorDetector.GestureEvent.STATE_GESTURE_COMPLETED; } else if (stateFlag == STATE_GESTURE_CANCELLED) { return ActiveGestureErrorDetector.GestureEvent.STATE_GESTURE_CANCELLED; } else if (stateFlag == STATE_SCREENSHOT_CAPTURED) { return ActiveGestureErrorDetector.GestureEvent.STATE_SCREENSHOT_CAPTURED; } else if (stateFlag == STATE_CAPTURE_SCREENSHOT) { return ActiveGestureErrorDetector.GestureEvent.STATE_CAPTURE_SCREENSHOT; } else if (stateFlag == STATE_HANDLER_INVALIDATED) { return ActiveGestureErrorDetector.GestureEvent.STATE_HANDLER_INVALIDATED; } return null; } Loading Loading @@ -1222,6 +1228,8 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, // Let RecentsView handle the scrolling to the task, which we launch in startNewTask() // or resumeLastTask(). if (mRecentsView != null) { ActiveGestureLog.INSTANCE.trackEvent(ActiveGestureErrorDetector.GestureEvent .SET_ON_PAGE_TRANSITION_END_CALLBACK); mRecentsView.setOnPageTransitionEndCallback( () -> mGestureState.setState(STATE_RECENTS_SCROLLING_FINISHED)); } else { Loading Loading @@ -1699,6 +1707,9 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, * handler (in case of quick switch). */ private void cancelCurrentAnimation() { ActiveGestureLog.INSTANCE.addLog( "AbsSwipeUpHandler.cancelCurrentAnimation", ActiveGestureErrorDetector.GestureEvent.CANCEL_CURRENT_ANIMATION); mCanceled = true; mCurrentShift.cancelAnimation(); Loading quickstep/src/com/android/quickstep/GestureState.java +2 −0 Original line number Diff line number Diff line Loading @@ -189,6 +189,8 @@ public class GestureState implements RecentsAnimationCallbacks.RecentsAnimationL return ActiveGestureErrorDetector.GestureEvent.STATE_END_TARGET_ANIMATION_FINISHED; } else if (stateFlag == STATE_RECENTS_SCROLLING_FINISHED) { return ActiveGestureErrorDetector.GestureEvent.STATE_RECENTS_SCROLLING_FINISHED; } else if (stateFlag == STATE_RECENTS_ANIMATION_CANCELED) { return ActiveGestureErrorDetector.GestureEvent.STATE_RECENTS_ANIMATION_CANCELED; } return null; } Loading quickstep/src/com/android/quickstep/RecentsAnimationController.java +8 −1 Original line number Diff line number Diff line Loading @@ -32,6 +32,8 @@ import androidx.annotation.UiThread; import com.android.launcher3.util.Preconditions; import com.android.launcher3.util.RunnableList; import com.android.quickstep.util.ActiveGestureErrorDetector; import com.android.quickstep.util.ActiveGestureLog; import com.android.systemui.shared.recents.model.ThumbnailData; import com.android.systemui.shared.system.InteractionJankMonitorWrapper; import com.android.systemui.shared.system.RecentsAnimationControllerCompat; Loading Loading @@ -172,7 +174,12 @@ public class RecentsAnimationController { */ @UiThread public void cleanupScreenshot() { UI_HELPER_EXECUTOR.execute(() -> mController.cleanupScreenshot()); UI_HELPER_EXECUTOR.execute(() -> { ActiveGestureLog.INSTANCE.addLog( "cleanupScreenshot", ActiveGestureErrorDetector.GestureEvent.CLEANUP_SCREENSHOT); mController.cleanupScreenshot(); }); } /** Loading quickstep/src/com/android/quickstep/TaskAnimationManager.java +4 −0 Original line number Diff line number Diff line Loading @@ -36,6 +36,8 @@ import androidx.annotation.UiThread; import com.android.launcher3.Utilities; import com.android.launcher3.config.FeatureFlags; import com.android.quickstep.TopTaskTracker.CachedTaskInfo; import com.android.quickstep.util.ActiveGestureErrorDetector; import com.android.quickstep.util.ActiveGestureLog; import com.android.quickstep.views.RecentsView; import com.android.systemui.shared.recents.model.ThumbnailData; import com.android.systemui.shared.system.ActivityManagerWrapper; Loading Loading @@ -136,6 +138,8 @@ public class TaskAnimationManager implements RecentsAnimationCallbacks.RecentsAn // handling this call entirely return; } ActiveGestureLog.INSTANCE.addLog("TaskAnimationManager.startRecentsAnimation", ActiveGestureErrorDetector.GestureEvent.START_RECENTS_ANIMATION); mController = controller; mTargets = targets; mLastAppearedTaskTarget = mTargets.findTask(mLastGestureState.getRunningTaskId()); Loading quickstep/src/com/android/quickstep/TouchInteractionService.java +25 −8 Original line number Diff line number Diff line Loading @@ -721,8 +721,10 @@ public class TouchInteractionService extends Service gestureState.updateRunningTask(taskInfo); } // Log initial state for the gesture. ActiveGestureLog.INSTANCE.addLog( "Current SystemUi state flags= " + mDeviceState.getSystemUiStateString()); ActiveGestureLog.INSTANCE.addLog(new CompoundString("Current running task package name=") .append(taskInfo == null ? "no running task" : taskInfo.getPackageName())); ActiveGestureLog.INSTANCE.addLog(new CompoundString("Current SystemUi state flags=") .append(mDeviceState.getSystemUiStateString())); return gestureState; } Loading Loading @@ -1024,12 +1026,27 @@ public class TouchInteractionService extends Service .append("activity == null, trying to use default input consumer")); } if (activity.getRootView().hasWindowFocus() || previousGestureState.isRunningAnimationToLauncher() || (ASSISTANT_GIVES_LAUNCHER_FOCUS.get() && forceOverviewInputConsumer) || (ENABLE_QUICKSTEP_LIVE_TILE.get() && gestureState.getActivityInterface().isInLiveTileMode())) { boolean hasWindowFocus = activity.getRootView().hasWindowFocus(); boolean isPreviousGestureAnimatingToLauncher = previousGestureState.isRunningAnimationToLauncher(); boolean forcingOverviewInputConsumer = ASSISTANT_GIVES_LAUNCHER_FOCUS.get() && forceOverviewInputConsumer; boolean isInLiveTileMode = ENABLE_QUICKSTEP_LIVE_TILE.get() && gestureState.getActivityInterface().isInLiveTileMode(); reasonString.append(SUBSTRING_PREFIX) .append(hasWindowFocus ? "activity has window focus" : (isPreviousGestureAnimatingToLauncher ? "previous gesture is still animating to launcher" : (forcingOverviewInputConsumer ? "assistant gives launcher focus and forcing focus" : (isInLiveTileMode ? "device is in live mode" : "all overview focus conditions failed")))); if (hasWindowFocus || isPreviousGestureAnimatingToLauncher || forcingOverviewInputConsumer || isInLiveTileMode) { reasonString.append(SUBSTRING_PREFIX) .append("overview should have focus, using OverviewInputConsumer"); return new OverviewInputConsumer(gestureState, activity, mInputMonitorCompat, Loading Loading
quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java +11 −0 Original line number Diff line number Diff line Loading @@ -334,6 +334,12 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, return ActiveGestureErrorDetector.GestureEvent.STATE_GESTURE_COMPLETED; } else if (stateFlag == STATE_GESTURE_CANCELLED) { return ActiveGestureErrorDetector.GestureEvent.STATE_GESTURE_CANCELLED; } else if (stateFlag == STATE_SCREENSHOT_CAPTURED) { return ActiveGestureErrorDetector.GestureEvent.STATE_SCREENSHOT_CAPTURED; } else if (stateFlag == STATE_CAPTURE_SCREENSHOT) { return ActiveGestureErrorDetector.GestureEvent.STATE_CAPTURE_SCREENSHOT; } else if (stateFlag == STATE_HANDLER_INVALIDATED) { return ActiveGestureErrorDetector.GestureEvent.STATE_HANDLER_INVALIDATED; } return null; } Loading Loading @@ -1222,6 +1228,8 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, // Let RecentsView handle the scrolling to the task, which we launch in startNewTask() // or resumeLastTask(). if (mRecentsView != null) { ActiveGestureLog.INSTANCE.trackEvent(ActiveGestureErrorDetector.GestureEvent .SET_ON_PAGE_TRANSITION_END_CALLBACK); mRecentsView.setOnPageTransitionEndCallback( () -> mGestureState.setState(STATE_RECENTS_SCROLLING_FINISHED)); } else { Loading Loading @@ -1699,6 +1707,9 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, * handler (in case of quick switch). */ private void cancelCurrentAnimation() { ActiveGestureLog.INSTANCE.addLog( "AbsSwipeUpHandler.cancelCurrentAnimation", ActiveGestureErrorDetector.GestureEvent.CANCEL_CURRENT_ANIMATION); mCanceled = true; mCurrentShift.cancelAnimation(); Loading
quickstep/src/com/android/quickstep/GestureState.java +2 −0 Original line number Diff line number Diff line Loading @@ -189,6 +189,8 @@ public class GestureState implements RecentsAnimationCallbacks.RecentsAnimationL return ActiveGestureErrorDetector.GestureEvent.STATE_END_TARGET_ANIMATION_FINISHED; } else if (stateFlag == STATE_RECENTS_SCROLLING_FINISHED) { return ActiveGestureErrorDetector.GestureEvent.STATE_RECENTS_SCROLLING_FINISHED; } else if (stateFlag == STATE_RECENTS_ANIMATION_CANCELED) { return ActiveGestureErrorDetector.GestureEvent.STATE_RECENTS_ANIMATION_CANCELED; } return null; } Loading
quickstep/src/com/android/quickstep/RecentsAnimationController.java +8 −1 Original line number Diff line number Diff line Loading @@ -32,6 +32,8 @@ import androidx.annotation.UiThread; import com.android.launcher3.util.Preconditions; import com.android.launcher3.util.RunnableList; import com.android.quickstep.util.ActiveGestureErrorDetector; import com.android.quickstep.util.ActiveGestureLog; import com.android.systemui.shared.recents.model.ThumbnailData; import com.android.systemui.shared.system.InteractionJankMonitorWrapper; import com.android.systemui.shared.system.RecentsAnimationControllerCompat; Loading Loading @@ -172,7 +174,12 @@ public class RecentsAnimationController { */ @UiThread public void cleanupScreenshot() { UI_HELPER_EXECUTOR.execute(() -> mController.cleanupScreenshot()); UI_HELPER_EXECUTOR.execute(() -> { ActiveGestureLog.INSTANCE.addLog( "cleanupScreenshot", ActiveGestureErrorDetector.GestureEvent.CLEANUP_SCREENSHOT); mController.cleanupScreenshot(); }); } /** Loading
quickstep/src/com/android/quickstep/TaskAnimationManager.java +4 −0 Original line number Diff line number Diff line Loading @@ -36,6 +36,8 @@ import androidx.annotation.UiThread; import com.android.launcher3.Utilities; import com.android.launcher3.config.FeatureFlags; import com.android.quickstep.TopTaskTracker.CachedTaskInfo; import com.android.quickstep.util.ActiveGestureErrorDetector; import com.android.quickstep.util.ActiveGestureLog; import com.android.quickstep.views.RecentsView; import com.android.systemui.shared.recents.model.ThumbnailData; import com.android.systemui.shared.system.ActivityManagerWrapper; Loading Loading @@ -136,6 +138,8 @@ public class TaskAnimationManager implements RecentsAnimationCallbacks.RecentsAn // handling this call entirely return; } ActiveGestureLog.INSTANCE.addLog("TaskAnimationManager.startRecentsAnimation", ActiveGestureErrorDetector.GestureEvent.START_RECENTS_ANIMATION); mController = controller; mTargets = targets; mLastAppearedTaskTarget = mTargets.findTask(mLastGestureState.getRunningTaskId()); Loading
quickstep/src/com/android/quickstep/TouchInteractionService.java +25 −8 Original line number Diff line number Diff line Loading @@ -721,8 +721,10 @@ public class TouchInteractionService extends Service gestureState.updateRunningTask(taskInfo); } // Log initial state for the gesture. ActiveGestureLog.INSTANCE.addLog( "Current SystemUi state flags= " + mDeviceState.getSystemUiStateString()); ActiveGestureLog.INSTANCE.addLog(new CompoundString("Current running task package name=") .append(taskInfo == null ? "no running task" : taskInfo.getPackageName())); ActiveGestureLog.INSTANCE.addLog(new CompoundString("Current SystemUi state flags=") .append(mDeviceState.getSystemUiStateString())); return gestureState; } Loading Loading @@ -1024,12 +1026,27 @@ public class TouchInteractionService extends Service .append("activity == null, trying to use default input consumer")); } if (activity.getRootView().hasWindowFocus() || previousGestureState.isRunningAnimationToLauncher() || (ASSISTANT_GIVES_LAUNCHER_FOCUS.get() && forceOverviewInputConsumer) || (ENABLE_QUICKSTEP_LIVE_TILE.get() && gestureState.getActivityInterface().isInLiveTileMode())) { boolean hasWindowFocus = activity.getRootView().hasWindowFocus(); boolean isPreviousGestureAnimatingToLauncher = previousGestureState.isRunningAnimationToLauncher(); boolean forcingOverviewInputConsumer = ASSISTANT_GIVES_LAUNCHER_FOCUS.get() && forceOverviewInputConsumer; boolean isInLiveTileMode = ENABLE_QUICKSTEP_LIVE_TILE.get() && gestureState.getActivityInterface().isInLiveTileMode(); reasonString.append(SUBSTRING_PREFIX) .append(hasWindowFocus ? "activity has window focus" : (isPreviousGestureAnimatingToLauncher ? "previous gesture is still animating to launcher" : (forcingOverviewInputConsumer ? "assistant gives launcher focus and forcing focus" : (isInLiveTileMode ? "device is in live mode" : "all overview focus conditions failed")))); if (hasWindowFocus || isPreviousGestureAnimatingToLauncher || forcingOverviewInputConsumer || isInLiveTileMode) { reasonString.append(SUBSTRING_PREFIX) .append("overview should have focus, using OverviewInputConsumer"); return new OverviewInputConsumer(gestureState, activity, mInputMonitorCompat, Loading