diff options
-rw-r--r-- | res/layout/call_log_list_item.xml | 6 | ||||
-rw-r--r-- | res/layout/call_log_list_item_actions.xml | 14 | ||||
-rw-r--r-- | res/values/dimens.xml | 10 | ||||
-rw-r--r-- | src/com/android/dialer/calllog/CallLogAdapter.java | 15 |
4 files changed, 16 insertions, 29 deletions
diff --git a/res/layout/call_log_list_item.xml b/res/layout/call_log_list_item.xml index bdf14774e..9899424c4 100644 --- a/res/layout/call_log_list_item.xml +++ b/res/layout/call_log_list_item.xml @@ -28,7 +28,7 @@ android:id="@+id/call_log_day_group_label" android:layout_width="match_parent" android:layout_height="wrap_content" - android:layout_marginStart="@dimen/call_log_outer_margin" + android:layout_marginStart="@dimen/call_log_start_margin" android:layout_marginEnd="@dimen/call_log_outer_margin" android:textColor="?attr/call_log_secondary_text_color" android:textSize="@dimen/call_log_secondary_text_size" @@ -52,7 +52,7 @@ android:background="@drawable/call_log_background" android:layout_width="match_parent" android:layout_height="wrap_content" - android:paddingStart="@dimen/call_log_outer_margin" + android:paddingStart="@dimen/call_log_start_margin" android:paddingEnd="@dimen/call_log_outer_margin" android:paddingTop="@dimen/call_log_outer_margin" android:paddingBottom="@dimen/call_log_outer_margin" @@ -75,7 +75,7 @@ android:layout_weight="1" android:orientation="vertical" android:gravity="center_vertical" - android:layout_marginStart="@dimen/call_log_inner_margin" + android:layout_marginStart="@dimen/call_log_start_margin" > <TextView android:id="@+id/name" diff --git a/res/layout/call_log_list_item_actions.xml b/res/layout/call_log_list_item_actions.xml index 9ee9a0fa5..3a93575c1 100644 --- a/res/layout/call_log_list_item_actions.xml +++ b/res/layout/call_log_list_item_actions.xml @@ -24,7 +24,7 @@ android:layout_width="match_parent" android:layout_height="@dimen/call_log_action_height" android:orientation="horizontal" - android:paddingLeft="@dimen/call_log_actions_left_padding" + android:paddingStart="@dimen/call_log_actions_left_padding" android:visibility="visible" android:importantForAccessibility="1" > @@ -35,8 +35,8 @@ android:gravity="center" android:layout_width="wrap_content" android:layout_height="match_parent" - android:paddingLeft="@dimen/call_log_action_horizontal_padding" - android:paddingRight="@dimen/call_log_action_horizontal_padding" + android:paddingStart="@dimen/call_log_action_horizontal_padding" + android:paddingEnd="@dimen/call_log_action_horizontal_padding" android:text="@string/call_log_action_call_back" android:textColor="@color/call_log_action_text" android:textSize="@dimen/call_log_secondary_text_size" @@ -51,8 +51,8 @@ android:gravity="center" android:layout_width="wrap_content" android:layout_height="match_parent" - android:paddingLeft="@dimen/call_log_action_horizontal_padding" - android:paddingRight="@dimen/call_log_action_horizontal_padding" + android:paddingStart="@dimen/call_log_action_horizontal_padding" + android:paddingEnd="@dimen/call_log_action_horizontal_padding" android:text="@string/call_log_action_voicemail" android:textColor="@color/call_log_action_text" android:textSize="@dimen/call_log_secondary_text_size" @@ -67,8 +67,8 @@ android:gravity="center" android:layout_width="wrap_content" android:layout_height="match_parent" - android:paddingLeft="@dimen/call_log_action_horizontal_padding" - android:paddingRight="@dimen/call_log_action_horizontal_padding" + android:paddingStart="@dimen/call_log_action_horizontal_padding" + android:paddingEnd="@dimen/call_log_action_horizontal_padding" android:text="@string/call_log_action_details" android:textColor="?attr/call_log_secondary_text_color" android:textSize="@dimen/call_log_secondary_text_size" diff --git a/res/values/dimens.xml b/res/values/dimens.xml index f399e368e..d2ef1cb7c 100644 --- a/res/values/dimens.xml +++ b/res/values/dimens.xml @@ -31,18 +31,12 @@ <dimen name="call_log_icon_margin">4dip</dimen> <dimen name="call_log_inner_margin">8dip</dimen> <dimen name="call_log_outer_margin">8dp</dimen> + <dimen name="call_log_start_margin">16dp</dimen> <dimen name="call_log_indent_margin">24dip</dimen> <dimen name="call_log_list_item_height">56dip</dimen> <dimen name="call_log_list_contact_photo_size">40dip</dimen> <dimen name="call_detail_contact_name_margin">24dip</dimen> <dimen name="call_detail_button_spacing">2dip</dimen> - <!-- Defines the vertical margin for the vertical separator between - the main area of a call log entry and the secondary action button. --> - <dimen name="call_log_list_item_vertical_divider_margin">17dp</dimen> - - <!-- Defines the width of the vertical separator between - the main area of a call log entry and the secondary action button. --> - <dimen name="call_log_list_item_vertical_divider_width">1dp</dimen> <!-- Match call_button_height to Phone's dimens/in_call_end_button_height --> <dimen name="call_button_height">74dp</dimen> @@ -123,7 +117,7 @@ to the right of the contact badge. Adjust when any of the following change: call_log_action_horizontal_padding call_log_list_contact_photo_size --> - <dimen name="call_log_actions_left_padding">48dp</dimen> + <dimen name="call_log_actions_left_padding">64dp</dimen> <!-- Text size for primary call log text --> <dimen name="call_log_primary_text_size">16sp</dimen> <!-- Text size for secondary call log text --> diff --git a/src/com/android/dialer/calllog/CallLogAdapter.java b/src/com/android/dialer/calllog/CallLogAdapter.java index 12d5531fd..9906513f8 100644 --- a/src/com/android/dialer/calllog/CallLogAdapter.java +++ b/src/com/android/dialer/calllog/CallLogAdapter.java @@ -22,7 +22,6 @@ import android.content.Intent; import android.content.res.Resources; import android.database.Cursor; import android.net.Uri; -import android.os.AsyncTask; import android.os.Handler; import android.os.Message; import android.provider.CallLog.Calls; @@ -35,7 +34,6 @@ import android.view.ViewStub; import android.view.ViewTreeObserver; import android.widget.ImageView; import android.widget.TextView; -import android.widget.Toast; import com.android.common.widget.GroupingListAdapter; import com.android.contacts.common.ContactPhotoManager; @@ -45,8 +43,6 @@ import com.android.contacts.common.util.UriUtils; import com.android.dialer.PhoneCallDetails; import com.android.dialer.PhoneCallDetailsHelper; import com.android.dialer.R; -import com.android.dialer.util.AsyncTaskExecutor; -import com.android.dialer.util.AsyncTaskExecutors; import com.android.dialer.util.ExpirableCache; import com.google.common.annotations.VisibleForTesting; @@ -126,10 +122,10 @@ public class CallLogAdapter extends GroupingListAdapter private static final int CONTACT_INFO_CACHE_SIZE = 100; /** Localized string representing the word "Today". */ - private static final CharSequence TODAY_LABEL = DateUtils.getTodayString(); + private final CharSequence mTodayLabel = DateUtils.getTodayString(); /** Localized string representing the word "Yesterday". */ - private static final CharSequence YESTERDAY_LABEL = DateUtils.getYesterdayString(); + private final CharSequence mYesterdayLabel = DateUtils.getYesterdayString(); /** Constant used to indicate no row is expanded. */ private static final long NONE_EXPANDED = -1; @@ -139,9 +135,6 @@ public class CallLogAdapter extends GroupingListAdapter private final CallFetcher mCallFetcher; private ViewTreeObserver mViewTreeObserver = null; - /** Aynchronous task executor, lazy instantiated as needed. */ - private AsyncTaskExecutor mAsyncTaskExecutor; - /** * A cache of the contact details for the phone numbers in the call log. * <p> @@ -1327,9 +1320,9 @@ public class CallLogAdapter extends GroupingListAdapter */ private CharSequence getGroupDescription(int group) { if (group == CallLogGroupBuilder.DAY_GROUP_TODAY) { - return TODAY_LABEL; + return mTodayLabel; } else if (group == CallLogGroupBuilder.DAY_GROUP_YESTERDAY) { - return YESTERDAY_LABEL; + return mYesterdayLabel; } else if (group == CallLogGroupBuilder.DAY_GROUP_LAST_WEEK) { return mContext.getResources().getString(R.string.call_log_header_last_week); } else { |