diff options
| author | 2017-08-02 16:57:11 +0200 | |
|---|---|---|
| committer | 2017-08-02 16:57:12 +0200 | |
| commit | 24dbff3f8963d5bf47dd0b63f76404b2d535582e (patch) | |
| tree | 9a8954205fb7c00642b764288b5f491879f60b91 | |
| parent | 273bb516ad875048bb14eb4f3f598c295c44991a (diff) | |
LightStatus: Fix notification icon color filter
Fixes an issue with the color filter applied to status bar icons where the
tint's alpha channel was ignored.
Change-Id: Idf22c70524fb718995d09ef339b825425ca5f7a7
Fixes: 64139391
Test: Look at light status bar with notifications; verify that icons have slightly gray tint instead of fully black
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/StatusBarIconView.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarIconView.java b/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarIconView.java index f5dc03858a37..27fe33e6b12f 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarIconView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/StatusBarIconView.java @@ -571,14 +571,14 @@ public class StatusBarIconView extends AnimatedImageView { /** * Updates {@param array} such that it represents a matrix that changes RGB to {@param color} - * and multiplies A with 1+{@param alphaBoost}. + * and multiplies the alpha channel with the color's alpha+{@param alphaBoost}. */ private static void updateTintMatrix(float[] array, int color, float alphaBoost) { Arrays.fill(array, 0); array[4] = Color.red(color); array[9] = Color.green(color); array[14] = Color.blue(color); - array[18] = 1 + alphaBoost; + array[18] = Color.alpha(color) / 255f + alphaBoost; } public void setIconColor(int iconColor, boolean animate) { |