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

Commit 8195500f authored by Chris Li's avatar Chris Li Committed by Automerger Merge Worker
Browse files

Merge "Call with Shell transition for TRANSIT_KEYGUARD_OCCLUDE/UNOCCLUDE" into...

Merge "Call with Shell transition for TRANSIT_KEYGUARD_OCCLUDE/UNOCCLUDE" into sc-v2-dev am: 3a39ccf9

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15436501

Change-Id: I507d7a9e32550f8b96056e8eec8886b69e315b5a
parents aa59c306 3a39ccf9
Loading
Loading
Loading
Loading
+10 −1
Original line number Original line Diff line number Diff line
@@ -4984,10 +4984,18 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp
        }
        }
    }
    }


    /**
     * @deprecated new transition should use {@link #requestTransitionAndLegacyPrepare(int, int)}
     */
    @Deprecated
    void prepareAppTransition(@WindowManager.TransitionType int transit) {
    void prepareAppTransition(@WindowManager.TransitionType int transit) {
        prepareAppTransition(transit, 0 /* flags */);
        prepareAppTransition(transit, 0 /* flags */);
    }
    }


    /**
     * @deprecated new transition should use {@link #requestTransitionAndLegacyPrepare(int, int)}
     */
    @Deprecated
    void prepareAppTransition(@WindowManager.TransitionType int transit,
    void prepareAppTransition(@WindowManager.TransitionType int transit,
            @WindowManager.TransitionFlags int flags) {
            @WindowManager.TransitionFlags int flags) {
        final boolean prepared = mAppTransition.prepareAppTransition(transit, flags);
        final boolean prepared = mAppTransition.prepareAppTransition(transit, flags);
@@ -5000,7 +5008,8 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp
     * Helper that both requests a transition (using the new transition system) and prepares
     * Helper that both requests a transition (using the new transition system) and prepares
     * the legacy transition system. Use this when both systems have the same start-point.
     * the legacy transition system. Use this when both systems have the same start-point.
     *
     *
     * @see TransitionController#requestTransitionIfNeeded(int, int, WindowContainer)
     * @see TransitionController#requestTransitionIfNeeded(int, int, WindowContainer,
     *      WindowContainer)
     * @see AppTransition#prepareAppTransition
     * @see AppTransition#prepareAppTransition
     */
     */
    void requestTransitionAndLegacyPrepare(@WindowManager.TransitionType int transit,
    void requestTransitionAndLegacyPrepare(@WindowManager.TransitionType int transit,
+2 −2
Original line number Original line Diff line number Diff line
@@ -378,10 +378,10 @@ class KeyguardController {
            mService.deferWindowLayout();
            mService.deferWindowLayout();
            try {
            try {
                mRootWindowContainer.getDefaultDisplay()
                mRootWindowContainer.getDefaultDisplay()
                        .prepareAppTransition(
                        .requestTransitionAndLegacyPrepare(
                                isDisplayOccluded(DEFAULT_DISPLAY)
                                isDisplayOccluded(DEFAULT_DISPLAY)
                                        ? TRANSIT_KEYGUARD_OCCLUDE
                                        ? TRANSIT_KEYGUARD_OCCLUDE
                                        : TRANSIT_KEYGUARD_UNOCCLUDE);
                                        : TRANSIT_KEYGUARD_UNOCCLUDE, 0 /* flags */);
                // When the occluding activity also turns on the display, visibility of the activity
                // When the occluding activity also turns on the display, visibility of the activity
                // can be committed before KEYGUARD_OCCLUDE transition is handled.
                // can be committed before KEYGUARD_OCCLUDE transition is handled.
                // Set mRequestForceTransition flag to make sure that the app transition animation
                // Set mRequestForceTransition flag to make sure that the app transition animation
+0 −1
Original line number Original line Diff line number Diff line
@@ -2811,7 +2811,6 @@ class RootWindowContainer extends WindowContainer<DisplayContent>
        Slog.w(TAG, "  Force finishing activity "
        Slog.w(TAG, "  Force finishing activity "
                + r.intent.getComponent().flattenToShortString());
                + r.intent.getComponent().flattenToShortString());
        r.detachFromProcess();
        r.detachFromProcess();
        r.mDisplayContent.prepareAppTransition(TRANSIT_CLOSE, TRANSIT_FLAG_APP_CRASHED);
        r.mDisplayContent.requestTransitionAndLegacyPrepare(TRANSIT_CLOSE,
        r.mDisplayContent.requestTransitionAndLegacyPrepare(TRANSIT_CLOSE,
                TRANSIT_FLAG_APP_CRASHED);
                TRANSIT_FLAG_APP_CRASHED);
        r.destroyIfPossible("handleAppCrashed");
        r.destroyIfPossible("handleAppCrashed");
+0 −2
Original line number Original line Diff line number Diff line
@@ -5266,7 +5266,6 @@ class Task extends TaskFragment {
        Slog.w(TAG, "  Force finishing activity "
        Slog.w(TAG, "  Force finishing activity "
                + r.intent.getComponent().flattenToShortString());
                + r.intent.getComponent().flattenToShortString());
        Task finishedTask = r.getTask();
        Task finishedTask = r.getTask();
        mDisplayContent.prepareAppTransition(TRANSIT_CLOSE, TRANSIT_FLAG_APP_CRASHED);
        mDisplayContent.requestTransitionAndLegacyPrepare(TRANSIT_CLOSE, TRANSIT_FLAG_APP_CRASHED);
        mDisplayContent.requestTransitionAndLegacyPrepare(TRANSIT_CLOSE, TRANSIT_FLAG_APP_CRASHED);
        r.finishIfPossible(reason, false /* oomAdj */);
        r.finishIfPossible(reason, false /* oomAdj */);


@@ -5646,7 +5645,6 @@ class Task extends TaskFragment {


        // Skip the transition for pinned task.
        // Skip the transition for pinned task.
        if (!inPinnedWindowingMode()) {
        if (!inPinnedWindowingMode()) {
            mDisplayContent.prepareAppTransition(TRANSIT_TO_BACK);
            mDisplayContent.requestTransitionAndLegacyPrepare(TRANSIT_TO_BACK, tr);
            mDisplayContent.requestTransitionAndLegacyPrepare(TRANSIT_TO_BACK, tr);
        }
        }
        moveToBack("moveTaskToBackLocked", tr);
        moveToBack("moveTaskToBackLocked", tr);