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

Commit 134924c1 authored by Riddle Hsu's avatar Riddle Hsu Committed by Android (Google) Code Review
Browse files

Merge "Remove inTransitionSelfOrParent" into main

parents 052d237b 05f24631
Loading
Loading
Loading
Loading
+1 −5
Original line number Diff line number Diff line
@@ -3795,7 +3795,7 @@ final class ActivityRecord extends WindowToken {
        }

        if (isCurrentVisible) {
            if (isNextNotYetVisible || delayRemoval || (next != null && isInTransition())) {
            if (isNextNotYetVisible || delayRemoval || (next != null && inTransition())) {
                // Add this activity to the list of stopping activities. It will be processed and
                // destroyed when the next activity reports idle.
                addToStopping(false /* scheduleIdle */, false /* idleDelayed */,
@@ -7941,10 +7941,6 @@ final class ActivityRecord extends WindowToken {
        }
    }

    boolean isInTransition() {
        return inTransitionSelfOrParent();
    }

    /**
     * In some cases, applying insets to bounds changes the orientation. For example, if a
     * close-to-square display rotates to portrait to respect a portrait orientation activity, after
+1 −1
Original line number Diff line number Diff line
@@ -116,7 +116,7 @@ class ActivityRecordInputSink {
        final boolean allowPassthrough = activityBelowInTask != null && (
                activityBelowInTask.mAllowedTouchUid == mActivityRecord.getUid()
                        || activityBelowInTask.isUid(mActivityRecord.getUid()));
        if (allowPassthrough || !mIsCompatEnabled || mActivityRecord.isInTransition()
        if (allowPassthrough || !mIsCompatEnabled || mActivityRecord.inTransition()
                || !mActivityRecord.mActivityRecordInputSinkEnabled) {
            // Set to non-touchable, so the touch events can pass through.
            mInputWindowHandleWrapper.setInputConfigMasked(InputConfig.NOT_TOUCHABLE,
+1 −1
Original line number Diff line number Diff line
@@ -2171,7 +2171,7 @@ public class ActivityTaskSupervisor implements RecentTasks.Callbacks {
            final ActivityRecord s = mStoppingActivities.get(i);
            // Activity in a force hidden task should not be counted as animating, i.e., we want to
            // send onStop before any configuration change when removing pip transition is ongoing.
            final boolean animating = s.isInTransition()
            final boolean animating = s.inTransition()
                    && s.getTask() != null && !s.getTask().isForceHidden();
            ProtoLog.v(WM_DEBUG_STATES, "Stopping %s: nowVisible=%b animating=%b "
                    + "finishing=%s", s, s.nowVisible, animating, s.finishing);
+2 −2
Original line number Diff line number Diff line
@@ -134,7 +134,7 @@ class AppCompatReachabilityPolicy {
        // The check on the transition state only makes sense if the event is coming from core.
        // In case the event is coming from Shell, the transition should not be considered.
        final boolean skipWhenOnTransition = source == REACHABILITY_SOURCE_CORE
                && mActivityRecord.isInTransition();
                && mActivityRecord.inTransition();
        if (!reachabilityOverrides.isHorizontalReachabilityEnabled() || skipWhenOnTransition) {
            return;
        }
@@ -183,7 +183,7 @@ class AppCompatReachabilityPolicy {
        // The check on the transition state only makes sense if the event is coming from core.
        // In case the event is coming from Shell, the transition should not be considered.
        final boolean skipWhenOnTransition = source == REACHABILITY_SOURCE_CORE
                && mActivityRecord.isInTransition();
                && mActivityRecord.inTransition();
        if (!reachabilityOverrides.isVerticalReachabilityEnabled() || skipWhenOnTransition) {
            return;
        }
+2 −2
Original line number Diff line number Diff line
@@ -2036,7 +2036,7 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp
        if (prevRotatedLaunchingApp != null
                && prevRotatedLaunchingApp.getWindowConfiguration().getRotation() == rotation
                // It is animating so we can expect there will have a transition callback.
                && (prevRotatedLaunchingApp.isInTransition())) {
                && prevRotatedLaunchingApp.inTransition()) {
            // It may be the case that multiple activities launch consecutively. Because their
            // rotation are the same, the transformed state can be shared to avoid duplicating
            // the heavy operations. This also benefits that the states of multiple activities
@@ -4388,7 +4388,7 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp
            final boolean nonAppImeLayeringTargetAnimatingExit = mImeLayeringTarget.mAnimatingExit
                    && mImeLayeringTarget.mAttrs.type != TYPE_BASE_APPLICATION
                    && mImeLayeringTarget.isSelfAnimating(0, ANIMATION_TYPE_WINDOW_ANIMATION);
            if (mImeLayeringTarget.inTransitionSelfOrParent()
            if (mImeLayeringTarget.inTransition()
                    || nonAppImeLayeringTargetAnimatingExit) {
                showImeScreenshot();
            }
Loading