summaryrefslogtreecommitdiff
path: root/quickstep/src
diff options
context:
space:
mode:
authorVinit Nayak <peanutbutter@google.com>2022-05-27 02:52:36 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2022-05-27 02:52:36 +0000
commite8a4e0e2dce6fec12ec0e2e841bb50f641f71d2d (patch)
tree824598b123c0bfec5fc1729f04af9dea30083a74 /quickstep/src
parent4ca247a6bb30387a4bc7f5260285ebe6e30df402 (diff)
parentf7b4e7f497437d8ce1df1632bba6dee7b61298c8 (diff)
downloadLauncher3-e8a4e0e2dce6fec12ec0e2e841bb50f641f71d2d.tar.gz
Merge "Limit starting bounds of swipe to animation start rect" into tm-dev
Diffstat (limited to 'quickstep/src')
-rw-r--r--quickstep/src/com/android/quickstep/SwipeUpAnimationLogic.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/quickstep/src/com/android/quickstep/SwipeUpAnimationLogic.java b/quickstep/src/com/android/quickstep/SwipeUpAnimationLogic.java
index 088e1cfc00..966710854f 100644
--- a/quickstep/src/com/android/quickstep/SwipeUpAnimationLogic.java
+++ b/quickstep/src/com/android/quickstep/SwipeUpAnimationLogic.java
@@ -266,6 +266,13 @@ public abstract class SwipeUpAnimationLogic implements
RectF cropRectF = new RectF(taskViewSimulator.getCurrentCropRect());
// Move the startRect to Launcher space as floatingIconView runs in Launcher
Matrix windowToHomePositionMap = new Matrix();
+
+ // If the start rect ends up overshooting too much to the left/right offscreen, bring it
+ // back to fullscreen. This can happen when the recentsScroll value isn't aligned with
+ // the pageScroll value for a given taskView, see b/228829958#comment12
+ mRemoteTargetHandles[0].getTaskViewSimulator().getOrientationState().getOrientationHandler()
+ .fixBoundsForHomeAnimStartRect(startRect, mDp);
+
homeToWindowPositionMap.invert(windowToHomePositionMap);
windowToHomePositionMap.mapRect(startRect);