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

Commit 080d3501 authored by Yunfan Chen's avatar Yunfan Chen Committed by Android (Google) Code Review
Browse files

Merge "Remove AppWindowContainerController and AppWindowContainerListener (39/n)"

parents 4faa3290 1ee84ea6
Loading
Loading
Loading
Loading
+318 −53

File changed.

Preview size limit exceeded, changes collapsed.

+4 −3
Original line number Original line Diff line number Diff line
@@ -3034,7 +3034,7 @@ class ActivityStack<T extends StackWindowController> extends ConfigurationContai
                    if (!startIt) {
                    if (!startIt) {
                        if (DEBUG_ADD_REMOVE) Slog.i(TAG, "Adding activity " + r + " to task "
                        if (DEBUG_ADD_REMOVE) Slog.i(TAG, "Adding activity " + r + " to task "
                                + task, new RuntimeException("here").fillInStackTrace());
                                + task, new RuntimeException("here").fillInStackTrace());
                        r.createWindowContainer();
                        r.createAppWindowToken();
                        ActivityOptions.abort(options);
                        ActivityOptions.abort(options);
                        return;
                        return;
                    }
                    }
@@ -3064,9 +3064,10 @@ class ActivityStack<T extends StackWindowController> extends ConfigurationContai
        // TODO: Need to investigate if it is okay for the controller to already be created by the
        // TODO: Need to investigate if it is okay for the controller to already be created by the
        // time we get to this point. I think it is, but need to double check.
        // time we get to this point. I think it is, but need to double check.
        // Use test in b/34179495 to trace the call path.
        // Use test in b/34179495 to trace the call path.
        if (r.getWindowContainerController() == null) {
        if (r.mAppWindowToken == null) {
            r.createWindowContainer();
            r.createAppWindowToken();
        }
        }

        task.setFrontOfTask();
        task.setFrontOfTask();


        if (!isHomeOrRecentsStack() || numActivities() > 0) {
        if (!isHomeOrRecentsStack() || numActivities() > 0) {
+1 −1
Original line number Original line Diff line number Diff line
@@ -1877,7 +1877,7 @@ public class ActivityStackSupervisor implements RecentTasks.Callbacks {
                "Added restored task=" + task + " to stack=" + stack);
                "Added restored task=" + task + " to stack=" + stack);
        final ArrayList<ActivityRecord> activities = task.mActivities;
        final ArrayList<ActivityRecord> activities = task.mActivities;
        for (int activityNdx = activities.size() - 1; activityNdx >= 0; --activityNdx) {
        for (int activityNdx = activities.size() - 1; activityNdx >= 0; --activityNdx) {
            activities.get(activityNdx).createWindowContainer();
            activities.get(activityNdx).createAppWindowToken();
        }
        }
        return true;
        return true;
    }
    }
+4 −5
Original line number Original line Diff line number Diff line
@@ -305,7 +305,7 @@ public class AppTransitionController {
            AppWindowToken wtoken = openingApps.valueAt(i);
            AppWindowToken wtoken = openingApps.valueAt(i);
            if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "Now opening app" + wtoken);
            if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "Now opening app" + wtoken);


            if (!wtoken.setVisibility(animLp, true, transit, false, voiceInteraction)) {
            if (!wtoken.commitVisibility(animLp, true, transit, false, voiceInteraction)) {
                // This token isn't going to be animating. Add it to the list of tokens to
                // This token isn't going to be animating. Add it to the list of tokens to
                // be notified of app transition complete since the notification will not be
                // be notified of app transition complete since the notification will not be
                // sent be the app window animator.
                // sent be the app window animator.
@@ -341,7 +341,7 @@ public class AppTransitionController {
            if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "Now closing app " + wtoken);
            if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "Now closing app " + wtoken);
            // TODO: Do we need to add to mNoAnimationNotifyOnTransitionFinished like above if not
            // TODO: Do we need to add to mNoAnimationNotifyOnTransitionFinished like above if not
            //       animating?
            //       animating?
            wtoken.setVisibility(animLp, false, transit, false, voiceInteraction);
            wtoken.commitVisibility(animLp, false, transit, false, voiceInteraction);
            wtoken.updateReportedVisibilityLocked();
            wtoken.updateReportedVisibilityLocked();
            // Force the allDrawn flag, because we want to start
            // Force the allDrawn flag, because we want to start
            // this guy's animations regardless of whether it's
            // this guy's animations regardless of whether it's
@@ -350,9 +350,8 @@ public class AppTransitionController {
            wtoken.deferClearAllDrawn = false;
            wtoken.deferClearAllDrawn = false;
            // Ensure that apps that are mid-starting are also scheduled to have their
            // Ensure that apps that are mid-starting are also scheduled to have their
            // starting windows removed after the animation is complete
            // starting windows removed after the animation is complete
            if (wtoken.startingWindow != null && !wtoken.startingWindow.mAnimatingExit
            if (wtoken.startingWindow != null && !wtoken.startingWindow.mAnimatingExit) {
                    && wtoken.getController() != null) {
                wtoken.removeStartingWindow();
                wtoken.getController().removeStartingWindow();
            }
            }


            if (mDisplayContent.mAppTransition.isNextAppTransitionThumbnailDown()) {
            if (mDisplayContent.mAppTransition.isNextAppTransitionThumbnailDown()) {
+0 −912

File deleted.

Preview size limit exceeded, changes collapsed.

Loading