Improvement to visual layout of call details.
Changes the styling for the call and SMS row, the history items, and
fixes the alignment of the name on top of the picture.
Bug: 5039572
Bug: 5121168
Change-Id: Ibeaa0621a7662d7537db0573a370f61f8a00e385
diff --git a/res/layout/call_detail.xml b/res/layout/call_detail.xml
index ece2f64..987a787 100644
--- a/res/layout/call_detail.xml
+++ b/res/layout/call_detail.xml
@@ -89,11 +89,12 @@
android:layout_width="wrap_content"
android:layout_height="0dip"
android:layout_alignLeft="@id/photo_text_bar"
- android:layout_alignTop="@id/photo_text_bar"
android:layout_toLeftOf="@id/main_action"
+ android:layout_alignTop="@id/photo_text_bar"
android:layout_alignBottom="@id/photo_text_bar"
android:layout_marginRight="@dimen/call_log_inner_margin"
android:layout_marginLeft="@dimen/call_detail_contact_name_margin"
+ android:gravity="center_vertical"
android:textColor="?attr/call_log_primary_text_color"
android:textSize="18sp"
android:singleLine="true"
@@ -113,14 +114,16 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/voicemail_container"
+ android:layout_marginTop="@dimen/call_log_icon_margin"
android:background="?attr/call_log_primary_background_color"
/>
<ListView
android:id="@+id/history"
android:layout_width="match_parent"
android:layout_height="wrap_content"
+ android:layout_marginTop="@dimen/call_log_icon_margin"
android:layout_alignParentLeft="true"
android:layout_below="@android:id/list"
- android:background="?attr/call_log_secondary_background_color"
+ android:background="@android:color/black"
/>
</RelativeLayout>
diff --git a/res/layout/call_detail_history_item.xml b/res/layout/call_detail_history_item.xml
index b225369..674b034 100644
--- a/res/layout/call_detail_history_item.xml
+++ b/res/layout/call_detail_history_item.xml
@@ -14,45 +14,46 @@
limitations under the License.
-->
-<RelativeLayout
+<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:minHeight="?android:attr/listPreferredItemHeight"
- android:background="?attr/call_log_secondary_background_color"
- android:padding="@dimen/call_log_indent_margin"
+ android:minHeight="@dimen/call_log_list_item_height"
+ android:paddingTop="@dimen/call_log_icon_margin"
+ android:paddingLeft="@dimen/call_log_indent_margin"
+ android:paddingRight="@dimen/call_log_outer_margin"
+ android:orientation="vertical"
>
- <view
- class="com.android.contacts.calllog.CallTypeIconsView"
- android:id="@+id/call_type_icon"
+ <LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_alignParentTop="true"
- android:layout_alignParentLeft="true"
- android:layout_marginRight="@dimen/call_log_icon_margin"
- />
- <TextView
- android:id="@+id/call_type_text"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_alignParentTop="true"
- android:layout_toRightOf="@id/call_type_icon"
- android:textColor="?attr/call_log_secondary_text_color"
- />
+ android:orientation="horizontal"
+ >
+ <view
+ class="com.android.contacts.calllog.CallTypeIconsView"
+ android:id="@+id/call_type_icon"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_gravity="center_vertical"
+ />
+ <TextView
+ android:id="@+id/call_type_text"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginLeft="@dimen/call_log_icon_margin"
+ android:textColor="@color/secondary_text_color"
+ />
+ </LinearLayout>
<TextView
android:id="@+id/date"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_below="@id/call_type_text"
- android:layout_alignLeft="@id/call_type_text"
- android:textColor="?attr/call_log_secondary_text_color"
+ android:textColor="@color/secondary_text_color"
/>
<TextView
android:id="@+id/duration"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_below="@id/date"
- android:layout_alignLeft="@id/date"
- android:textColor="?attr/call_log_secondary_text_color"
+ android:textColor="@color/secondary_text_color"
/>
-</RelativeLayout>
+</LinearLayout>
diff --git a/res/layout/call_detail_list_item.xml b/res/layout/call_detail_list_item.xml
index 8b90e25..e2bf83c 100644
--- a/res/layout/call_detail_list_item.xml
+++ b/res/layout/call_detail_list_item.xml
@@ -16,22 +16,22 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
- android:layout_height="wrap_content"
+ android:layout_height="@dimen/call_log_list_item_height"
android:orientation="horizontal"
- android:paddingLeft="9dip"
- android:paddingRight="5dip"
+ android:layout_marginTop="@dimen/call_log_icon_margin"
android:gravity="center_vertical"
+ android:background="@drawable/dialpad_background"
>
- <LinearLayout
+ <LinearLayout android:id="@+id/main_action"
android:layout_width="0dip"
- android:layout_height="wrap_content"
+ android:layout_height="match_parent"
android:layout_weight="1"
- android:layout_marginRight="5dip"
- android:paddingTop="5dip"
- android:paddingBottom="7dip"
+ android:paddingLeft="@dimen/call_log_indent_margin"
android:orientation="vertical"
android:gravity="center_vertical"
+ android:focusable="true"
+ android:background="@drawable/btn_dial"
>
<TextView android:id="@android:id/text1"
@@ -53,7 +53,7 @@
android:textAppearance="?android:attr/textAppearanceSmall"
android:textStyle="bold"
/>
-
+
<TextView android:id="@+id/number"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -63,12 +63,22 @@
</LinearLayout>
- <ImageView android:id="@+id/icon"
- android:layout_width="32dip"
+ <View android:id="@+id/divider"
+ android:layout_width="1px"
android:layout_height="32dip"
- android:layout_marginLeft="5dip"
+ android:background="@drawable/ic_divider_dashed_holo_dark"
+ android:layout_gravity="center_vertical"
+ />
+
+ <ImageView android:id="@+id/icon"
+ android:layout_width="@color/call_log_voicemail_highlight_color"
+ android:layout_height="match_parent"
+ android:paddingLeft="@dimen/call_log_inner_margin"
+ android:paddingRight="@dimen/call_log_outer_margin"
android:gravity="center"
android:scaleType="centerInside"
+ android:focusable="true"
+ android:background="@drawable/btn_dial"
/>
</LinearLayout>