summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/FastBitmapDrawable.java
diff options
context:
space:
mode:
authorTony Wickham <twickham@google.com>2017-06-07 14:32:23 -0700
committerTony Wickham <twickham@google.com>2017-06-08 21:08:47 +0000
commit7092db02410562026da17a7b38f48025cc847de2 (patch)
treef1c0c5a50594ce890109bdb25dd0346dee9cbf6d /src/com/android/launcher3/FastBitmapDrawable.java
parent85b64c7da0f1134fdbae954acbc2925c1433566a (diff)
downloadandroid_packages_apps_Trebuchet-7092db02410562026da17a7b38f48025cc847de2.tar.gz
android_packages_apps_Trebuchet-7092db02410562026da17a7b38f48025cc847de2.tar.bz2
android_packages_apps_Trebuchet-7092db02410562026da17a7b38f48025cc847de2.zip
Add support for color extracted notification dots
Changing the badge_color in colors.xml to transparent will cause them to be color extracted. When an extracted color is used in the IconPalette, we desaturate the background. Otherwise we respect the exact color specified in colors.xml. Change-Id: Ie82d0c5335fa5f24d4cc47766e4c1719c4916f8b
Diffstat (limited to 'src/com/android/launcher3/FastBitmapDrawable.java')
-rw-r--r--src/com/android/launcher3/FastBitmapDrawable.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/android/launcher3/FastBitmapDrawable.java b/src/com/android/launcher3/FastBitmapDrawable.java
index a096a1ddf..199baaf58 100644
--- a/src/com/android/launcher3/FastBitmapDrawable.java
+++ b/src/com/android/launcher3/FastBitmapDrawable.java
@@ -124,7 +124,7 @@ public class FastBitmapDrawable extends Drawable {
public IconPalette getIconPalette() {
if (mIconPalette == null) {
mIconPalette = IconPalette.fromDominantColor(Utilities
- .findDominantColorByHue(mBitmap, 20));
+ .findDominantColorByHue(mBitmap, 20), true /* desaturateBackground */);
}
return mIconPalette;
}