summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTony Wickham <twickham@google.com>2018-07-27 22:21:28 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2018-07-27 22:21:28 +0000
commitc1de7779466597c27469a6693227fb858c6a311f (patch)
treec7ebecdee26f2cae550c5036cb47c20d9673319f
parentae71e086a2fc23257e3d6de895883135d95d7144 (diff)
parentdfb785afc168f51d082382eca5a1d97e3f733734 (diff)
downloadandroid_packages_apps_Trebuchet-c1de7779466597c27469a6693227fb858c6a311f.tar.gz
android_packages_apps_Trebuchet-c1de7779466597c27469a6693227fb858c6a311f.tar.bz2
android_packages_apps_Trebuchet-c1de7779466597c27469a6693227fb858c6a311f.zip
Merge "Fix gap between notification dots and their shadows" into ub-launcher3-edmonton-polish
-rw-r--r--src/com/android/launcher3/graphics/ShadowGenerator.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/com/android/launcher3/graphics/ShadowGenerator.java b/src/com/android/launcher3/graphics/ShadowGenerator.java
index 5fbf502aa..88da853d6 100644
--- a/src/com/android/launcher3/graphics/ShadowGenerator.java
+++ b/src/com/android/launcher3/graphics/ShadowGenerator.java
@@ -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);