Correct insets for getNonMinimizedSplitScreenSecondaryBounds
Fixed the addition error on seascape and added top insets for launcher
to get correct bounds.
Change-Id: I963e69dcba7b20d138ba01e361f21186b773a264
Fixes: 79209096
Test: manual
diff --git a/packages/SystemUI/src/com/android/systemui/stackdivider/DividerView.java b/packages/SystemUI/src/com/android/systemui/stackdivider/DividerView.java
index 79fea9f..c8ee8735 100644
--- a/packages/SystemUI/src/com/android/systemui/stackdivider/DividerView.java
+++ b/packages/SystemUI/src/com/android/systemui/stackdivider/DividerView.java
@@ -376,15 +376,15 @@
public Rect getNonMinimizedSplitScreenSecondaryBounds() {
calculateBoundsForPosition(mSnapTargetBeforeMinimized.position,
DockedDividerUtils.invertDockSide(mDockSide), mOtherTaskRect);
+ mOtherTaskRect.bottom -= mStableInsets.bottom;
switch (mDockSide) {
case WindowManager.DOCKED_LEFT:
+ mOtherTaskRect.top += mStableInsets.top;
mOtherTaskRect.right -= mStableInsets.right;
break;
case WindowManager.DOCKED_RIGHT:
- mOtherTaskRect.left -= mStableInsets.left;
- break;
- case WindowManager.DOCKED_TOP:
- mOtherTaskRect.bottom -= mStableInsets.bottom;
+ mOtherTaskRect.top += mStableInsets.top;
+ mOtherTaskRect.left += mStableInsets.left;
break;
}
return mOtherTaskRect;