Loading packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java +1 −0 Original line number Diff line number Diff line Loading @@ -303,6 +303,7 @@ public class BubbleStackView extends FrameLayout { */ public void onConfigChanged() { for (Bubble b: mBubbleData.getBubbles()) { b.iconView.updateViews(); b.expandedView.updateHeaderColor(); } } Loading packages/SystemUI/src/com/android/systemui/bubbles/BubbleView.java +9 −4 Original line number Diff line number Diff line Loading @@ -159,7 +159,7 @@ public class BubbleView extends FrameLayout { } } private void updateViews() { void updateViews() { if (mEntry == null) { return; } Loading @@ -186,6 +186,13 @@ public class BubbleView extends FrameLayout { } private Drawable buildIconWithTint(Drawable iconDrawable, int backgroundColor) { iconDrawable = checkTint(iconDrawable, backgroundColor); InsetDrawable foreground = new InsetDrawable(iconDrawable, mIconInset); ColorDrawable background = new ColorDrawable(backgroundColor); return new AdaptiveIconDrawable(background, foreground); } private Drawable checkTint(Drawable iconDrawable, int backgroundColor) { backgroundColor = ColorUtils.setAlphaComponent(backgroundColor, 255 /* alpha */); if (backgroundColor == Color.TRANSPARENT) { // ColorUtils throws exception when background is translucent. Loading @@ -197,9 +204,7 @@ public class BubbleView extends FrameLayout { int dark = ColorUtils.setAlphaComponent(Color.BLACK, DARK_ICON_ALPHA); iconDrawable.setTint(dark); } InsetDrawable foreground = new InsetDrawable(iconDrawable, mIconInset); ColorDrawable background = new ColorDrawable(backgroundColor); return new AdaptiveIconDrawable(background, foreground); return iconDrawable; } private int determineDominateColor(Drawable d, int defaultTint) { Loading Loading
packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java +1 −0 Original line number Diff line number Diff line Loading @@ -303,6 +303,7 @@ public class BubbleStackView extends FrameLayout { */ public void onConfigChanged() { for (Bubble b: mBubbleData.getBubbles()) { b.iconView.updateViews(); b.expandedView.updateHeaderColor(); } } Loading
packages/SystemUI/src/com/android/systemui/bubbles/BubbleView.java +9 −4 Original line number Diff line number Diff line Loading @@ -159,7 +159,7 @@ public class BubbleView extends FrameLayout { } } private void updateViews() { void updateViews() { if (mEntry == null) { return; } Loading @@ -186,6 +186,13 @@ public class BubbleView extends FrameLayout { } private Drawable buildIconWithTint(Drawable iconDrawable, int backgroundColor) { iconDrawable = checkTint(iconDrawable, backgroundColor); InsetDrawable foreground = new InsetDrawable(iconDrawable, mIconInset); ColorDrawable background = new ColorDrawable(backgroundColor); return new AdaptiveIconDrawable(background, foreground); } private Drawable checkTint(Drawable iconDrawable, int backgroundColor) { backgroundColor = ColorUtils.setAlphaComponent(backgroundColor, 255 /* alpha */); if (backgroundColor == Color.TRANSPARENT) { // ColorUtils throws exception when background is translucent. Loading @@ -197,9 +204,7 @@ public class BubbleView extends FrameLayout { int dark = ColorUtils.setAlphaComponent(Color.BLACK, DARK_ICON_ALPHA); iconDrawable.setTint(dark); } InsetDrawable foreground = new InsetDrawable(iconDrawable, mIconInset); ColorDrawable background = new ColorDrawable(backgroundColor); return new AdaptiveIconDrawable(background, foreground); return iconDrawable; } private int determineDominateColor(Drawable d, int defaultTint) { Loading