mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-20 11:18:21 +00:00
Fix gap between notification dots and their shadows
There was a rounding issue due to usnig integer division when we meant float Bug: 73331123 Change-Id: Ic3deb1c26aa00808a929e1303602656ce532963d
This commit is contained in:
@@ -126,13 +126,13 @@ public class ShadowGenerator {
|
||||
}
|
||||
|
||||
public Bitmap createPill(int width, int height) {
|
||||
radius = height / 2;
|
||||
radius = height / 2f;
|
||||
|
||||
int centerX = Math.round(width / 2 + shadowBlur);
|
||||
int centerX = Math.round(width / 2f + shadowBlur);
|
||||
int centerY = Math.round(radius + shadowBlur + keyShadowDistance);
|
||||
int center = Math.max(centerX, centerY);
|
||||
bounds.set(0, 0, width, height);
|
||||
bounds.offsetTo(center - width / 2, center - height / 2);
|
||||
bounds.offsetTo(center - width / 2f, center - height / 2f);
|
||||
|
||||
int size = center * 2;
|
||||
Bitmap result = Bitmap.createBitmap(size, size, Config.ARGB_8888);
|
||||
|
||||
Reference in New Issue
Block a user