Fix widget drop preview outline on 4x5 grids am: ed82e0daef

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15351419

Change-Id: Iec817973aaea5eebddf3e09ecf0f6d97ff304999
This commit is contained in:
Adam Cohen authored and Automerger Merge Worker committed 2021-07-22 22:54:27 +00:00
commit 8b9d662114
1 file changed
+3 -2
+3 -2
View File
@@ -566,9 +566,10 @@ public class CellLayout extends ViewGroup {
int spanX = mDragOutlines[i].cellHSpan;
int spanY = mDragOutlines[i].cellVSpan;
// TODO b/194414754 clean this up, reconcile with cellToRect
mVisualizeGridRect.set(paddingX, paddingY,
mCellWidth * spanX - paddingX,
mCellHeight * spanY - paddingY);
mCellWidth * spanX + mBorderSpacing * (spanX - 1) - paddingX,
mCellHeight * spanY + mBorderSpacing * (spanY - 1) - paddingY);
int transX = x * mCellWidth + (x * mBorderSpacing)
+ getPaddingLeft() + paddingX;