Skip to content
Snippets Groups Projects
Commit 4434cec8 authored by Fabian Kozynski's avatar Fabian Kozynski
Browse files

Fix signal color in dark mode

Test: manual
Fixes: 180521630
Change-Id: I8021f078382bd1b6513091f4a4b59832629b09db
parent 109836d6
No related branches found
No related tags found
No related merge requests found
......@@ -90,6 +90,7 @@ public class QuickStatusBarHeader extends RelativeLayout implements LifecycleOwn
private OngoingPrivacyChip mPrivacyChip;
private Space mSpace;
private BatteryMeterView mBatteryRemainingIcon;
private TintedIconManager mTintedIconManager;
// Used for RingerModeTracker
private final LifecycleRegistry mLifecycle = new LifecycleRegistry(this);
......@@ -144,6 +145,7 @@ public class QuickStatusBarHeader extends RelativeLayout implements LifecycleOwn
}
void onAttach(TintedIconManager iconManager) {
mTintedIconManager = iconManager;
int fillColor = Utils.getColorAttrDefaultColor(getContext(),
android.R.attr.textColorPrimary);
......@@ -268,6 +270,9 @@ public class QuickStatusBarHeader extends RelativeLayout implements LifecycleOwn
android.R.attr.textColorSecondary);
mTextColorPrimary = textColor;
mClockView.setTextColor(textColor);
if (mTintedIconManager != null) {
mTintedIconManager.setTint(textColor);
}
mBatteryRemainingIcon.updateColors(mTextColorPrimary, textColorSecondary,
mTextColorPrimary);
}
......
......@@ -24,7 +24,6 @@ import static com.android.systemui.statusbar.StatusBarIconView.STATE_ICON;
import android.content.Context;
import android.content.res.ColorStateList;
import android.graphics.Color;
import android.graphics.Rect;
import android.util.AttributeSet;
import android.util.FeatureFlagUtils;
......@@ -238,11 +237,7 @@ public class StatusBarMobileView extends FrameLayout implements DarkReceiver,
@Override
public void setStaticDrawableColor(int color) {
ColorStateList list = ColorStateList.valueOf(color);
float intensity = color == Color.WHITE ? 0 : 1;
// We want the ability to change the theme from the one set by SignalDrawable in certain
// surfaces. In this way, we can pass a theme to the view.
mMobileDrawable.setTintList(
ColorStateList.valueOf(mDualToneHandler.getSingleColor(intensity)));
mMobileDrawable.setTintList(list);
mIn.setImageTintList(list);
mOut.setImageTintList(list);
mMobileType.setImageTintList(list);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment