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

Commit af4ca905 authored by Tony Wickham's avatar Tony Wickham
Browse files

Redraw live tile in updatePageOffsets()

Also finish recents controller in RecentsView#reset() if it hasn't
been already.

Test: in 2 button mode, swipe up from overview when a live tile is
running, ensure it moves offscreen with its TaskView; after swiping
from overview to home, tap nav bar to ensure controller was finished
Test2: in 0 button mode, open Maps, start directions, swipe up to
home and ensure PiP starts

Fixes: 185588376
Change-Id: I03c18b14b4f55f1f09ce3bc442de23c94aa170bf
parent 5241e3eb
Loading
Loading
Loading
Loading
+12 −1
Original line number Diff line number Diff line
@@ -1516,7 +1516,14 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
        mTaskListChangeId = -1;
        mFocusedTaskId = -1;

        if (mRecentsAnimationController != null) {
            if (LIVE_TILE.get() && mEnableDrawingLiveTile) {
                // We are still drawing the live tile, finish it now to clean up.
                finishRecentsAnimation(true /* toRecents */, null);
            } else {
                mRecentsAnimationController = null;
            }
        }
        mLiveTileParams.setTargetSet(null);
        mLiveTileTaskViewSimulator.setDrawsBelowRecents(true);

@@ -2621,6 +2628,10 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T
                    ? ((TaskView) child).getPrimaryTaskOffsetTranslationProperty()
                    : mOrientationHandler.getPrimaryViewTranslate();
            translationProperty.set(child, totalTranslation);
            if (LIVE_TILE.get() && mEnableDrawingLiveTile && i == getRunningTaskIndex()) {
                mLiveTileTaskViewSimulator.taskPrimaryTranslation.value = totalTranslation;
                redrawLiveTile();
            }
        }
        updateCurveProperties();
    }