Loading core/java/android/window/TransitionInfo.java +12 −0 Original line number Original line Diff line number Diff line Loading @@ -352,6 +352,7 @@ public final class TransitionInfo implements Parcelable { private final Rect mEndAbsBounds = new Rect(); private final Rect mEndAbsBounds = new Rect(); private final Point mEndRelOffset = new Point(); private final Point mEndRelOffset = new Point(); private ActivityManager.RunningTaskInfo mTaskInfo = null; private ActivityManager.RunningTaskInfo mTaskInfo = null; private boolean mAllowEnterPip; private int mStartRotation = ROTATION_UNDEFINED; private int mStartRotation = ROTATION_UNDEFINED; private int mEndRotation = ROTATION_UNDEFINED; private int mEndRotation = ROTATION_UNDEFINED; private int mRotationAnimation = ROTATION_ANIMATION_UNSPECIFIED; private int mRotationAnimation = ROTATION_ANIMATION_UNSPECIFIED; Loading @@ -372,6 +373,7 @@ public final class TransitionInfo implements Parcelable { mEndAbsBounds.readFromParcel(in); mEndAbsBounds.readFromParcel(in); mEndRelOffset.readFromParcel(in); mEndRelOffset.readFromParcel(in); mTaskInfo = in.readTypedObject(ActivityManager.RunningTaskInfo.CREATOR); mTaskInfo = in.readTypedObject(ActivityManager.RunningTaskInfo.CREATOR); mAllowEnterPip = in.readBoolean(); mStartRotation = in.readInt(); mStartRotation = in.readInt(); mEndRotation = in.readInt(); mEndRotation = in.readInt(); mRotationAnimation = in.readInt(); mRotationAnimation = in.readInt(); Loading Loading @@ -415,6 +417,11 @@ public final class TransitionInfo implements Parcelable { mTaskInfo = taskInfo; mTaskInfo = taskInfo; } } /** Sets the allowEnterPip flag which represents AppOpsManager check on PiP permission */ public void setAllowEnterPip(boolean allowEnterPip) { mAllowEnterPip = allowEnterPip; } /** Sets the start and end rotation of this container. */ /** Sets the start and end rotation of this container. */ public void setRotation(@Surface.Rotation int start, @Surface.Rotation int end) { public void setRotation(@Surface.Rotation int start, @Surface.Rotation int end) { mStartRotation = start; mStartRotation = start; Loading Loading @@ -492,6 +499,10 @@ public final class TransitionInfo implements Parcelable { return mTaskInfo; return mTaskInfo; } } public boolean getAllowEnterPip() { return mAllowEnterPip; } public int getStartRotation() { public int getStartRotation() { return mStartRotation; return mStartRotation; } } Loading @@ -517,6 +528,7 @@ public final class TransitionInfo implements Parcelable { mEndAbsBounds.writeToParcel(dest, flags); mEndAbsBounds.writeToParcel(dest, flags); mEndRelOffset.writeToParcel(dest, flags); mEndRelOffset.writeToParcel(dest, flags); dest.writeTypedObject(mTaskInfo, flags); dest.writeTypedObject(mTaskInfo, flags); dest.writeBoolean(mAllowEnterPip); dest.writeInt(mStartRotation); dest.writeInt(mStartRotation); dest.writeInt(mEndRotation); dest.writeInt(mEndRotation); dest.writeInt(mRotationAnimation); dest.writeInt(mRotationAnimation); Loading packages/SystemUI/shared/src/com/android/systemui/shared/system/RemoteAnimationTargetCompat.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -216,7 +216,7 @@ public class RemoteAnimationTargetCompat { activityType = ACTIVITY_TYPE_UNDEFINED; activityType = ACTIVITY_TYPE_UNDEFINED; } } taskInfo = change.getTaskInfo(); taskInfo = change.getTaskInfo(); allowEnterPip = false; /* always false in shell-transition case */ allowEnterPip = change.getAllowEnterPip(); mStartLeash = null; mStartLeash = null; rotationChange = change.getEndRotation() - change.getStartRotation(); rotationChange = change.getEndRotation() - change.getStartRotation(); windowType = INVALID_WINDOW_TYPE; windowType = INVALID_WINDOW_TYPE; Loading services/core/java/com/android/server/wm/Transition.java +3 −0 Original line number Original line Diff line number Diff line Loading @@ -1070,6 +1070,9 @@ class Transition extends Binder implements BLASTSyncEngine.TransactionReadyListe task.fillTaskInfo(tinfo); task.fillTaskInfo(tinfo); change.setTaskInfo(tinfo); change.setTaskInfo(tinfo); change.setRotationAnimation(getTaskRotationAnimation(task)); change.setRotationAnimation(getTaskRotationAnimation(task)); final ActivityRecord topMostActivity = task.getTopMostActivity(); change.setAllowEnterPip(topMostActivity != null && topMostActivity.checkEnterPictureInPictureAppOpsState()); } } out.addChange(change); out.addChange(change); } } Loading Loading
core/java/android/window/TransitionInfo.java +12 −0 Original line number Original line Diff line number Diff line Loading @@ -352,6 +352,7 @@ public final class TransitionInfo implements Parcelable { private final Rect mEndAbsBounds = new Rect(); private final Rect mEndAbsBounds = new Rect(); private final Point mEndRelOffset = new Point(); private final Point mEndRelOffset = new Point(); private ActivityManager.RunningTaskInfo mTaskInfo = null; private ActivityManager.RunningTaskInfo mTaskInfo = null; private boolean mAllowEnterPip; private int mStartRotation = ROTATION_UNDEFINED; private int mStartRotation = ROTATION_UNDEFINED; private int mEndRotation = ROTATION_UNDEFINED; private int mEndRotation = ROTATION_UNDEFINED; private int mRotationAnimation = ROTATION_ANIMATION_UNSPECIFIED; private int mRotationAnimation = ROTATION_ANIMATION_UNSPECIFIED; Loading @@ -372,6 +373,7 @@ public final class TransitionInfo implements Parcelable { mEndAbsBounds.readFromParcel(in); mEndAbsBounds.readFromParcel(in); mEndRelOffset.readFromParcel(in); mEndRelOffset.readFromParcel(in); mTaskInfo = in.readTypedObject(ActivityManager.RunningTaskInfo.CREATOR); mTaskInfo = in.readTypedObject(ActivityManager.RunningTaskInfo.CREATOR); mAllowEnterPip = in.readBoolean(); mStartRotation = in.readInt(); mStartRotation = in.readInt(); mEndRotation = in.readInt(); mEndRotation = in.readInt(); mRotationAnimation = in.readInt(); mRotationAnimation = in.readInt(); Loading Loading @@ -415,6 +417,11 @@ public final class TransitionInfo implements Parcelable { mTaskInfo = taskInfo; mTaskInfo = taskInfo; } } /** Sets the allowEnterPip flag which represents AppOpsManager check on PiP permission */ public void setAllowEnterPip(boolean allowEnterPip) { mAllowEnterPip = allowEnterPip; } /** Sets the start and end rotation of this container. */ /** Sets the start and end rotation of this container. */ public void setRotation(@Surface.Rotation int start, @Surface.Rotation int end) { public void setRotation(@Surface.Rotation int start, @Surface.Rotation int end) { mStartRotation = start; mStartRotation = start; Loading Loading @@ -492,6 +499,10 @@ public final class TransitionInfo implements Parcelable { return mTaskInfo; return mTaskInfo; } } public boolean getAllowEnterPip() { return mAllowEnterPip; } public int getStartRotation() { public int getStartRotation() { return mStartRotation; return mStartRotation; } } Loading @@ -517,6 +528,7 @@ public final class TransitionInfo implements Parcelable { mEndAbsBounds.writeToParcel(dest, flags); mEndAbsBounds.writeToParcel(dest, flags); mEndRelOffset.writeToParcel(dest, flags); mEndRelOffset.writeToParcel(dest, flags); dest.writeTypedObject(mTaskInfo, flags); dest.writeTypedObject(mTaskInfo, flags); dest.writeBoolean(mAllowEnterPip); dest.writeInt(mStartRotation); dest.writeInt(mStartRotation); dest.writeInt(mEndRotation); dest.writeInt(mEndRotation); dest.writeInt(mRotationAnimation); dest.writeInt(mRotationAnimation); Loading
packages/SystemUI/shared/src/com/android/systemui/shared/system/RemoteAnimationTargetCompat.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -216,7 +216,7 @@ public class RemoteAnimationTargetCompat { activityType = ACTIVITY_TYPE_UNDEFINED; activityType = ACTIVITY_TYPE_UNDEFINED; } } taskInfo = change.getTaskInfo(); taskInfo = change.getTaskInfo(); allowEnterPip = false; /* always false in shell-transition case */ allowEnterPip = change.getAllowEnterPip(); mStartLeash = null; mStartLeash = null; rotationChange = change.getEndRotation() - change.getStartRotation(); rotationChange = change.getEndRotation() - change.getStartRotation(); windowType = INVALID_WINDOW_TYPE; windowType = INVALID_WINDOW_TYPE; Loading
services/core/java/com/android/server/wm/Transition.java +3 −0 Original line number Original line Diff line number Diff line Loading @@ -1070,6 +1070,9 @@ class Transition extends Binder implements BLASTSyncEngine.TransactionReadyListe task.fillTaskInfo(tinfo); task.fillTaskInfo(tinfo); change.setTaskInfo(tinfo); change.setTaskInfo(tinfo); change.setRotationAnimation(getTaskRotationAnimation(task)); change.setRotationAnimation(getTaskRotationAnimation(task)); final ActivityRecord topMostActivity = task.getTopMostActivity(); change.setAllowEnterPip(topMostActivity != null && topMostActivity.checkEnterPictureInPictureAppOpsState()); } } out.addChange(change); out.addChange(change); } } Loading