diff options
author | Nancy Chen <nancychen@google.com> | 2014-05-23 11:03:21 -0700 |
---|---|---|
committer | Nancy Chen <nancychen@google.com> | 2014-05-23 11:41:07 -0700 |
commit | f88b7b9d1a07414053a4a90d13d453a02bd58ac7 (patch) | |
tree | 71254516ea29d21929d19e3306ec177db8f6fd59 /src/com/android/contacts/common/list/ContactListItemView.java | |
parent | 914484fec1f71e1f336fab5e81b310e3edab229e (diff) | |
download | android_packages_apps_ContactsCommon-f88b7b9d1a07414053a4a90d13d453a02bd58ac7.tar.gz android_packages_apps_ContactsCommon-f88b7b9d1a07414053a4a90d13d453a02bd58ac7.tar.bz2 android_packages_apps_ContactsCommon-f88b7b9d1a07414053a4a90d13d453a02bd58ac7.zip |
Add attibute for color on contacts list search items
Adding the ability to change the color on the contacts list
search items. The actual colors are defined in Dialer.
Bug: 15118603
Change-Id: I8e332e9c448cbcc4e4f64349d9ff5474bb06eb2f
Diffstat (limited to 'src/com/android/contacts/common/list/ContactListItemView.java')
-rw-r--r-- | src/com/android/contacts/common/list/ContactListItemView.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/com/android/contacts/common/list/ContactListItemView.java b/src/com/android/contacts/common/list/ContactListItemView.java index 186ee8b4..5d3ff3ce 100644 --- a/src/com/android/contacts/common/list/ContactListItemView.java +++ b/src/com/android/contacts/common/list/ContactListItemView.java @@ -186,6 +186,7 @@ public class ContactListItemView extends ViewGroup private boolean mPhotoViewWidthAndHeightAreReady = false; private int mNameTextViewHeight; + private int mNameTextViewTextColor; private int mPhoneticNameTextViewHeight; private int mLabelViewHeight; private int mDataViewHeight; @@ -251,6 +252,9 @@ public class ContactListItemView extends ViewGroup mLabelViewWidthWeight = a.getInteger( R.styleable.ContactListItemView_list_item_label_width_weight, mLabelViewWidthWeight); + mNameTextViewTextColor = a.getColor( + R.styleable.ContactListItemView_list_item_name_text_color, + mNameTextViewTextColor); setPaddingRelative( a.getDimensionPixelOffset( @@ -833,6 +837,7 @@ public class ContactListItemView extends ViewGroup mNameTextView.setSingleLine(true); mNameTextView.setEllipsize(getTextEllipsis()); mNameTextView.setTextAppearance(getContext(), R.style.TextAppearanceMedium); + mNameTextView.setTextColor(mNameTextViewTextColor); // Manually call setActivated() since this view may be added after the first // setActivated() call toward this whole item view. mNameTextView.setActivated(isActivated()); |