mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-18 02:08:20 +00:00
Merge "Update icon badges to match spec" into ub-launcher3-dorval
am: 0fa96ea2f6
Change-Id: I5f8e6bdbca13435d54e3b636564f7d3eef58ca5c
This commit is contained in:
@@ -2245,16 +2245,12 @@ public class Workspace extends PagedView
|
||||
Point dragVisualizeOffset = null;
|
||||
Rect dragRect = null;
|
||||
if (child instanceof BubbleTextView) {
|
||||
int iconSize = grid.iconSizePx;
|
||||
int top = child.getPaddingTop();
|
||||
int left = (b.getWidth() - iconSize) / 2;
|
||||
int right = left + iconSize;
|
||||
int bottom = top + iconSize;
|
||||
dragLayerY += top;
|
||||
// Note: The drag region is used to calculate drag layer offsets, but the
|
||||
dragRect = new Rect();
|
||||
((BubbleTextView) child).getIconBounds(dragRect);
|
||||
dragLayerY += dragRect.top;
|
||||
// Note: The dragRect is used to calculate drag layer offsets, but the
|
||||
// dragVisualizeOffset in addition to the dragRect (the size) to position the outline.
|
||||
dragVisualizeOffset = new Point(- halfPadding, halfPadding);
|
||||
dragRect = new Rect(left, top, right, bottom);
|
||||
} else if (child instanceof FolderIcon) {
|
||||
int previewSize = grid.folderIconSizePx;
|
||||
dragVisualizeOffset = new Point(- halfPadding, halfPadding - child.getPaddingTop());
|
||||
|
||||
Reference in New Issue
Block a user