diff options
author | Andrew Lee <anwlee@google.com> | 2014-06-06 14:13:21 -0700 |
---|---|---|
committer | Andrew Lee <anwlee@google.com> | 2014-06-06 14:13:21 -0700 |
commit | b2687dd09eef2fc1aaf31ea4a3edf523677108a8 (patch) | |
tree | e5d8ff5b28356008ad749dfd2089d75bc19804b1 /src | |
parent | 97c57ccec07ac91bacb71699b10dcdd24b750c3c (diff) |
UI improvements on tabs, recent expanded card, speed dial grid.
- Changed tab weight from bold to medium.
- Darkened the lists background by ~2% black to improve contrast
for the expanded call log items.
- Fixed colors on the expanded call log item, back to white.
- Some cleanup to store constant properties as member variables
in the CallLogAdapter.
- Fixed vertical margins on the speed dial favorite square views.
Bug: 15470880
Change-Id: Ia2583f527e1fc91af08e049312eaa724176b761d
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/dialer/calllog/CallLogAdapter.java | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/com/android/dialer/calllog/CallLogAdapter.java b/src/com/android/dialer/calllog/CallLogAdapter.java index 924a17fc2..4ef197719 100644 --- a/src/com/android/dialer/calllog/CallLogAdapter.java +++ b/src/com/android/dialer/calllog/CallLogAdapter.java @@ -254,6 +254,10 @@ public class CallLogAdapter extends GroupingListAdapter private ImageView mBadgeImageView; private TextView mBadgeText; + private int mCallLogBackgroundColor; + private int mExpandedBackgroundColor; + private float mExpandedTranslationZ; + /** Listener for the primary or secondary actions in the list. * Primary opens the call details. * Secondary calls or plays. @@ -355,6 +359,9 @@ public class CallLogAdapter extends GroupingListAdapter Resources resources = mContext.getResources(); CallTypeHelper callTypeHelper = new CallTypeHelper(resources); + mCallLogBackgroundColor = resources.getColor(R.color.background_dialer_list_items); + mExpandedBackgroundColor = resources.getColor(R.color.call_log_expanded_background_color); + mExpandedTranslationZ = resources.getDimension(R.dimen.call_log_expanded_translation_z); mContactPhotoManager = ContactPhotoManager.getInstance(mContext); mPhoneNumberHelper = new PhoneNumberDisplayHelper(resources); @@ -862,10 +869,8 @@ public class CallLogAdapter extends GroupingListAdapter views.actionsView.setVisibility(View.VISIBLE); views.actionsView.setAlpha(1.0f); - views.callLogEntryView.setBackgroundColor( - callLogItem.getResources().getColor(R.color.background_dialer_light)); - callLogItem.setTranslationZ(callLogItem.getResources().getDimension( - R.dimen.call_log_expanded_translation_z)); + views.callLogEntryView.setBackgroundColor(mExpandedBackgroundColor); + callLogItem.setTranslationZ(mExpandedTranslationZ); // Attempt to give accessibility focus to one of the action buttons. // This ensures that a user realizes the expansion occurred. @@ -882,8 +887,7 @@ public class CallLogAdapter extends GroupingListAdapter views.actionsView.setVisibility(View.GONE); } - views.callLogEntryView.setBackgroundColor( - callLogItem.getResources().getColor(R.color.background_dialer_list_items)); + views.callLogEntryView.setBackgroundColor(mCallLogBackgroundColor); callLogItem.setTranslationZ(0); } } |