diff --git a/quickstep/src/com/android/quickstep/RecentsActivity.java b/quickstep/src/com/android/quickstep/RecentsActivity.java index 68526420ef..0e85ec3760 100644 --- a/quickstep/src/com/android/quickstep/RecentsActivity.java +++ b/quickstep/src/com/android/quickstep/RecentsActivity.java @@ -353,7 +353,8 @@ public final class RecentsActivity extends StatefulActivity { public void startHome() { if (LIVE_TILE.get()) { RecentsView recentsView = getOverviewPanel(); - recentsView.switchToScreenshotAndFinishAnimationToRecents(this::startHomeInternal); + recentsView.switchToScreenshot(() -> recentsView.finishRecentsAnimation(true, + this::startHomeInternal)); } else { startHomeInternal(); } diff --git a/quickstep/src/com/android/quickstep/views/RecentsView.java b/quickstep/src/com/android/quickstep/views/RecentsView.java index 7991614abb..df7f8b5a2a 100644 --- a/quickstep/src/com/android/quickstep/views/RecentsView.java +++ b/quickstep/src/com/android/quickstep/views/RecentsView.java @@ -2357,7 +2357,8 @@ public abstract class RecentsView onEnd(success)); + finishRecentsAnimation(true /* toRecents */, false /* shouldPip */, + () -> onEnd(success)); } else { onEnd(success); } @@ -2368,7 +2369,8 @@ public abstract class RecentsView { + finishRecentsAnimation(true /* toRecents */, false /* shouldPip */, + () -> { UI_HELPER_EXECUTOR.getHandler().postDelayed(() -> ActivityManagerWrapper.getInstance().removeTask( taskView.getTask().key.id), @@ -2478,7 +2480,7 @@ public abstract class RecentsView { if (isSuccess) { // Remove all the task views now - switchToScreenshotAndFinishAnimationToRecents(() -> { + finishRecentsAnimation(true /* toRecents */, false /* shouldPip */, () -> { UI_HELPER_EXECUTOR.getHandler().postDelayed( ActivityManagerWrapper.getInstance()::removeAllRecentTasks, REMOVE_TASK_WAIT_FOR_APP_STOP_MS); @@ -2639,7 +2641,9 @@ public abstract class RecentsView finishRecentsAnimation(true /* toRecents */, false /* showPip */, + this::updateRecentsRotation)); mEnableDrawingLiveTile = false; } else { updateRecentsRotation(); @@ -3632,10 +3636,6 @@ public abstract class RecentsView finishRecentsAnimation(true /* toRecents */, onFinishRunnable)); - } - /** * Switch the current running task view to static snapshot mode, * capturing the snapshot at the same time.