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

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

Merge "Do not wrap activity surface if it is handled by rotator" into main

parents c9729d7e e1212c05
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -94,6 +94,11 @@ public class CounterRotatorHelper {
        return rotatedBounds;
    }

    /** Returns true if the change is put on a surface in previous rotation. */
    public boolean isRotated(@NonNull TransitionInfo.Change change) {
        return mLastRotationDelta != 0 && mRotatorMap.containsKey(change.getParent());
    }

    /**
     * Removes the counter rotation surface in the finish transaction. No need to reparent the
     * children as the finish transaction should have already taken care of that.
+2 −1
Original line number Diff line number Diff line
@@ -517,7 +517,8 @@ public class DefaultTransitionHandler implements Transitions.TransitionHandler {
                    animRelOffset.y = Math.max(animRelOffset.y, change.getEndRelOffset().y);
                }

                if (change.getActivityComponent() != null && !isActivityLevel) {
                if (change.getActivityComponent() != null && !isActivityLevel
                        && !mRotator.isRotated(change)) {
                    // At this point, this is an independent activity change in a non-activity
                    // transition. This means that an activity transition got erroneously combined
                    // with another ongoing transition. This then means that the animation root may