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

Commit ff359219 authored by Tony's avatar Tony
Browse files

Fix task icon not showing if you press home

Instead of setting the icon scale to 0 in showTask(), which is
called whenever we get a new intent, only set it to 0 when
starting the swipe up gesture.

Change-Id: I657a1c5763c60b65e28f453ffe854ae8dab83bbc
parent 5f72d3b8
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -478,9 +478,7 @@ public class RecentsView extends PagedView implements Insettable {
        mRunningTaskId = runningTaskId;
        setCurrentPage(mFirstTaskIndex);
        if (mCurrentPage >= mFirstTaskIndex) {
            TaskView currentTask = (TaskView) getPageAt(mCurrentPage);
            currentTask.setIconScale(0);
            currentTask.setAlpha(0);
            getPageAt(mCurrentPage).setAlpha(0);
        }
    }

+9 −1
Original line number Diff line number Diff line
@@ -569,6 +569,14 @@ public class WindowTransformSwipeHandler extends BaseSwipeInteractionHandler {
     */
    private void notifyGestureStarted() {
        mLauncher.onQuickstepGestureStarted(mWasLauncherAlreadyVisible);

        mMainExecutor.execute(() -> {
            // Prepare to animate the first icon.
            View currentRecentsPage = mRecentsView.getPageAt(mRecentsView.getCurrentPage());
            if (currentRecentsPage instanceof TaskView) {
                ((TaskView) currentRecentsPage).setIconScale(0f);
            }
        });
    }

    @WorkerThread
@@ -673,7 +681,7 @@ public class WindowTransformSwipeHandler extends BaseSwipeInteractionHandler {
        // Re apply state in case we did something funky during the transition.
        mLauncher.getStateManager().reapplyState();

        // Animate ui the first icon.
        // Animate the first icon.
        View currentRecentsPage = mRecentsView.getPageAt(mRecentsView.getCurrentPage());
        if (currentRecentsPage instanceof TaskView) {
            ((TaskView) currentRecentsPage).animateIconToScale(1f);