diff options
author | Eric Erfanian <erfanian@google.com> | 2018-06-26 09:36:32 -0700 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2018-06-26 09:36:32 -0700 |
commit | ee0371753257a3db0cce37f5dffae7ac6ebf34b2 (patch) | |
tree | ab53eb4dde7f86f4af7efef76a9519ad363fc382 /java/com/android/incallui/incall/impl/CheckableLabeledButton.java | |
parent | 4e07384eef35d08526d7eeb2090a1932a3ee5a96 (diff) | |
parent | a3624bf414450b3dd35a8b358db1a2ffd7dee21a (diff) |
Merge changes Ib3ed6636,I10e10124,I84dbef78,I7ba7b0d8,Id00e8e3e am: b394d18d9f am: 9dc597525b
am: a3624bf414
Change-Id: I903f24709ad8ab70b62cc4f092c80197f8c10d22
Diffstat (limited to 'java/com/android/incallui/incall/impl/CheckableLabeledButton.java')
-rw-r--r-- | java/com/android/incallui/incall/impl/CheckableLabeledButton.java | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/java/com/android/incallui/incall/impl/CheckableLabeledButton.java b/java/com/android/incallui/incall/impl/CheckableLabeledButton.java index bfc2781a9..4e8fa82c4 100644 --- a/java/com/android/incallui/incall/impl/CheckableLabeledButton.java +++ b/java/com/android/incallui/incall/impl/CheckableLabeledButton.java @@ -18,14 +18,11 @@ package com.android.incallui.incall.impl; import android.animation.AnimatorInflater; import android.content.Context; -import android.content.res.ColorStateList; import android.content.res.TypedArray; -import android.graphics.Color; import android.graphics.PorterDuff.Mode; import android.graphics.drawable.Drawable; import android.os.Parcel; import android.os.Parcelable; -import android.support.annotation.ColorInt; import android.support.annotation.DrawableRes; import android.support.annotation.StringRes; import android.text.TextUtils.TruncateAt; @@ -36,6 +33,7 @@ import android.widget.Checkable; import android.widget.ImageView; import android.widget.LinearLayout; import android.widget.TextView; +import com.android.dialer.theme.base.ThemeComponent; /** A button to show on the incall screen */ public class CheckableLabeledButton extends LinearLayout implements Checkable { @@ -94,8 +92,7 @@ public class CheckableLabeledButton extends LinearLayout implements Checkable { iconView.setPadding(iconPadding, iconPadding, iconPadding, iconPadding); iconView.setImageDrawable(icon); iconView.setImageTintMode(Mode.SRC_IN); - iconView.setImageTintList( - getResources().getColorStateList(R.color.incall_button_icon, context.getTheme())); + iconView.setImageTintList(ThemeComponent.get(context).theme().getColorIconStateList()); iconView.setBackground( getResources().getDrawable(R.drawable.incall_button_background, context.getTheme())); @@ -134,13 +131,6 @@ public class CheckableLabeledButton extends LinearLayout implements Checkable { labelView.setAlpha(isEnabled() ? 1f : DISABLED_STATE_OPACITY); } - public void setCheckedColor(@ColorInt int color) { - iconView.setImageTintList( - new ColorStateList( - new int[][] {new int[] {android.R.attr.state_checked}, new int[] {}}, - new int[] {color, Color.WHITE})); - } - public Drawable getIconDrawable() { return iconView.getDrawable(); } |