Loading quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java +1 −0 Original line number Diff line number Diff line Loading @@ -1413,6 +1413,7 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, .setStartBounds(startRect) .setDestinationBounds(destinationBounds) .setCornerRadius(mRecentsView.getPipCornerRadius()) .setShadowRadius(mRecentsView.getPipShadowRadius()) .setAttachedView(mRecentsView); // We would assume home and app window always in the same rotation While homeRotation // is not ROTATION_0 (which implies the rotation is turned on in launcher settings). Loading quickstep/src/com/android/quickstep/util/SwipePipToHomeAnimator.java +10 −2 Original line number Diff line number Diff line Loading @@ -101,6 +101,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { * @param fromRotation From rotation if different from final rotation, ROTATION_0 otherwise * @param destinationBoundsTransformed Destination bounds in window space * @param cornerRadius Corner radius in pixel value for PiP window * @param shadowRadius Shadow radius in pixel value for PiP window * @param view Attached view for logging purpose */ private SwipePipToHomeAnimator(@NonNull Context context, Loading @@ -115,6 +116,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { @RecentsOrientedState.SurfaceRotation int fromRotation, @NonNull Rect destinationBoundsTransformed, int cornerRadius, int shadowRadius, @NonNull View view) { super(startBounds, new RectF(destinationBoundsTransformed), context, null); mTaskId = taskId; Loading @@ -126,7 +128,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { mDestinationBounds.set(destinationBounds); mFromRotation = fromRotation; mDestinationBoundsTransformed.set(destinationBoundsTransformed); mSurfaceTransactionHelper = new PipSurfaceTransactionHelper(cornerRadius); mSurfaceTransactionHelper = new PipSurfaceTransactionHelper(cornerRadius, shadowRadius); if (sourceRectHint != null && (sourceRectHint.width() < destinationBounds.width() || sourceRectHint.height() < destinationBounds.height())) { Loading Loading @@ -324,6 +326,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { private RectF mStartBounds; private Rect mDestinationBounds; private int mCornerRadius; private int mShadowRadius; private View mAttachedView; private @RecentsOrientedState.SurfaceRotation int mFromRotation = Surface.ROTATION_0; private final Rect mDestinationBoundsTransformed = new Rect(); Loading Loading @@ -378,6 +381,11 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { return this; } public Builder setShadowRadius(int shadowRadius) { mShadowRadius = shadowRadius; return this; } public Builder setAttachedView(View attachedView) { mAttachedView = attachedView; return this; Loading Loading @@ -422,7 +430,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { mSourceRectHint, mAppBounds, mHomeToWindowPositionMap, mStartBounds, mDestinationBounds, mFromRotation, mDestinationBoundsTransformed, mCornerRadius, mAttachedView); mCornerRadius, mShadowRadius, mAttachedView); } } Loading quickstep/src/com/android/quickstep/views/RecentsView.java +11 −1 Original line number Diff line number Diff line Loading @@ -539,6 +539,7 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T private final PinnedStackAnimationListener mIPipAnimationListener = new PinnedStackAnimationListener(); private int mPipCornerRadius; private int mPipShadowRadius; // Used to keep track of the last requested task list id, so that we do not request to load the // tasks again if we have already requested it and the task list has not changed Loading Loading @@ -5004,6 +5005,14 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T return mPipCornerRadius; } /** * @return Shadow radius in pixel value for PiP window, which is updated via * {@link #mIPipAnimationListener} */ public int getPipShadowRadius() { return mPipShadowRadius; } @Override public boolean scrollLeft() { if (!showAsGrid()) { Loading Loading @@ -5099,9 +5108,10 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T } @Override public void onPipCornerRadiusChanged(int cornerRadius) { public void onPipResourceDimensionsChanged(int cornerRadius, int shadowRadius) { if (mRecentsView != null) { mRecentsView.mPipCornerRadius = cornerRadius; mRecentsView.mPipShadowRadius = shadowRadius; } } Loading Loading
quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java +1 −0 Original line number Diff line number Diff line Loading @@ -1413,6 +1413,7 @@ public abstract class AbsSwipeUpHandler<T extends StatefulActivity<S>, .setStartBounds(startRect) .setDestinationBounds(destinationBounds) .setCornerRadius(mRecentsView.getPipCornerRadius()) .setShadowRadius(mRecentsView.getPipShadowRadius()) .setAttachedView(mRecentsView); // We would assume home and app window always in the same rotation While homeRotation // is not ROTATION_0 (which implies the rotation is turned on in launcher settings). Loading
quickstep/src/com/android/quickstep/util/SwipePipToHomeAnimator.java +10 −2 Original line number Diff line number Diff line Loading @@ -101,6 +101,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { * @param fromRotation From rotation if different from final rotation, ROTATION_0 otherwise * @param destinationBoundsTransformed Destination bounds in window space * @param cornerRadius Corner radius in pixel value for PiP window * @param shadowRadius Shadow radius in pixel value for PiP window * @param view Attached view for logging purpose */ private SwipePipToHomeAnimator(@NonNull Context context, Loading @@ -115,6 +116,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { @RecentsOrientedState.SurfaceRotation int fromRotation, @NonNull Rect destinationBoundsTransformed, int cornerRadius, int shadowRadius, @NonNull View view) { super(startBounds, new RectF(destinationBoundsTransformed), context, null); mTaskId = taskId; Loading @@ -126,7 +128,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { mDestinationBounds.set(destinationBounds); mFromRotation = fromRotation; mDestinationBoundsTransformed.set(destinationBoundsTransformed); mSurfaceTransactionHelper = new PipSurfaceTransactionHelper(cornerRadius); mSurfaceTransactionHelper = new PipSurfaceTransactionHelper(cornerRadius, shadowRadius); if (sourceRectHint != null && (sourceRectHint.width() < destinationBounds.width() || sourceRectHint.height() < destinationBounds.height())) { Loading Loading @@ -324,6 +326,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { private RectF mStartBounds; private Rect mDestinationBounds; private int mCornerRadius; private int mShadowRadius; private View mAttachedView; private @RecentsOrientedState.SurfaceRotation int mFromRotation = Surface.ROTATION_0; private final Rect mDestinationBoundsTransformed = new Rect(); Loading Loading @@ -378,6 +381,11 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { return this; } public Builder setShadowRadius(int shadowRadius) { mShadowRadius = shadowRadius; return this; } public Builder setAttachedView(View attachedView) { mAttachedView = attachedView; return this; Loading Loading @@ -422,7 +430,7 @@ public class SwipePipToHomeAnimator extends RectFSpringAnim { mSourceRectHint, mAppBounds, mHomeToWindowPositionMap, mStartBounds, mDestinationBounds, mFromRotation, mDestinationBoundsTransformed, mCornerRadius, mAttachedView); mCornerRadius, mShadowRadius, mAttachedView); } } Loading
quickstep/src/com/android/quickstep/views/RecentsView.java +11 −1 Original line number Diff line number Diff line Loading @@ -539,6 +539,7 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T private final PinnedStackAnimationListener mIPipAnimationListener = new PinnedStackAnimationListener(); private int mPipCornerRadius; private int mPipShadowRadius; // Used to keep track of the last requested task list id, so that we do not request to load the // tasks again if we have already requested it and the task list has not changed Loading Loading @@ -5004,6 +5005,14 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T return mPipCornerRadius; } /** * @return Shadow radius in pixel value for PiP window, which is updated via * {@link #mIPipAnimationListener} */ public int getPipShadowRadius() { return mPipShadowRadius; } @Override public boolean scrollLeft() { if (!showAsGrid()) { Loading Loading @@ -5099,9 +5108,10 @@ public abstract class RecentsView<ACTIVITY_TYPE extends StatefulActivity<STATE_T } @Override public void onPipCornerRadiusChanged(int cornerRadius) { public void onPipResourceDimensionsChanged(int cornerRadius, int shadowRadius) { if (mRecentsView != null) { mRecentsView.mPipCornerRadius = cornerRadius; mRecentsView.mPipShadowRadius = shadowRadius; } } Loading