summaryrefslogtreecommitdiff
path: root/java/com/android/dialer/voicemail
diff options
context:
space:
mode:
authoruabdullah <uabdullah@google.com>2018-03-09 15:27:36 -0800
committerCopybara-Service <copybara-piper@google.com>2018-03-09 16:50:34 -0800
commit909073ecd295b7e31965ea9e614673b66e97dbbf (patch)
treef76747a8eab2d352712f3afef5f00bd1d735a2f7 /java/com/android/dialer/voicemail
parentc7d8b13abe7641bb6058f05bcc46cd12d5798901 (diff)
Implement redlines for NUI VM Tab
Makes the redlines similar to what we have for the call log nui. The values are structured and copied as much as possible from /calllog/ui/res/layout/new_call_log_*.xml Things to note for: -Today/Older header the same as call log -More items all the way to the right -Padding in voicemail icon gone -Removed padding between each recycler view item Bug: 69963448 Test: N/A PiperOrigin-RevId: 188547442 Change-Id: I515d75e392591243510634c3fabe444a7ba10d7f
Diffstat (limited to 'java/com/android/dialer/voicemail')
-rw-r--r--java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_call_log_fragment.xml6
-rw-r--r--java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry.xml35
-rw-r--r--java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry_header.xml10
-rw-r--r--java/com/android/dialer/voicemail/listui/res/values/dimens.xml13
4 files changed, 25 insertions, 39 deletions
diff --git a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_call_log_fragment.xml b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_call_log_fragment.xml
index fd9e0f2d2..7bada6abe 100644
--- a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_call_log_fragment.xml
+++ b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_call_log_fragment.xml
@@ -26,11 +26,9 @@
android:id="@+id/new_voicemail_call_log_recycler_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:paddingBottom="@dimen/floating_action_button_list_bottom_padding"
android:background="@color/background_dialer_light"
- android:clipToPadding="false"
- android:visibility="gone"
- />
+ android:paddingBottom="88dp"
+ android:clipToPadding="false"/>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
diff --git a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry.xml b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry.xml
index fc98f0210..c6e5938c7 100644
--- a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry.xml
+++ b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry.xml
@@ -19,24 +19,20 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="@dimen/call_log_entry_top_margin"
- android:paddingTop="@dimen/call_log_entry_padding_top_start"
- android:paddingBottom="@dimen/call_log_entry_padding_bottom_end"
- android:paddingStart="@dimen/call_log_entry_padding_top_start"
- android:paddingEnd="@dimen/call_log_entry_padding_bottom_end"
- android:gravity="center_vertical">
+ android:minHeight="72dp">
<QuickContactBadge
android:id="@+id/quick_contact_photo"
- android:layout_width="@dimen/call_log_entry_photo_size"
- android:layout_height="@dimen/call_log_entry_photo_size"
- android:padding="@dimen/call_log_entry_photo_padding"
+ android:layout_width="40dp"
+ android:layout_height="40dp"
+ android:layout_marginTop="14dp"
+ android:layout_marginStart="16dp"
+ android:layout_marginEnd="16dp"
android:focusable="true"/>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_centerVertical="true"
android:layout_toEndOf="@+id/quick_contact_photo"
android:layout_toStartOf="@+id/menu_button"
android:orientation="vertical">
@@ -46,8 +42,12 @@
style="@style/PrimaryText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_marginStart="@dimen/call_log_entry_photo_text_margin"
- android:layout_gravity="center_vertical"/>
+ android:layout_weight="1"
+ android:layout_marginEnd="6dp"
+ android:layout_marginTop="14dp"
+ android:ellipsize="end"
+ android:lineSpacingMultiplier="1.5"
+ android:singleLine="true"/>
<LinearLayout
android:layout_width="wrap_content"
@@ -55,9 +55,8 @@
android:orientation="horizontal">
<ImageView
- android:layout_width="@dimen/voicemail_icon_size"
- android:layout_height="@dimen/voicemail_icon_size"
- android:layout_marginStart="@dimen/voicemail_icon_margin"
+ android:layout_width="wrap_content"
+ android:layout_height="18dp"
android:layout_gravity="center_vertical"
android:src="@drawable/quantum_ic_voicemail_vd_theme_24"
android:tint="@color/dialtacts_theme_color"
@@ -69,7 +68,9 @@
style="@style/SecondaryText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_marginStart="@dimen/call_log_entry_photo_text_margin"/>
+ android:ellipsize="end"
+ android:lineSpacingMultiplier="1.4"
+ android:singleLine="true"/>
</LinearLayout>
<!-- TODO(a bug): Fix text cropping issue, make text selectable -->
@@ -78,7 +79,6 @@
style="@style/PrimaryText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_marginStart="@dimen/call_log_entry_photo_text_margin"
android:layout_gravity="center_vertical"
android:textSize="@dimen/voicemail_transcription_text_size"
android:visibility="gone"/>
@@ -88,7 +88,6 @@
style="@style/SecondaryText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_marginStart="@dimen/call_log_entry_photo_text_margin"
android:layout_gravity="center_vertical"
android:text="@string/voicemail_transcription_branding_text"
android:visibility="gone"/>
diff --git a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry_header.xml b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry_header.xml
index 84fcc377e..7e4fe62cf 100644
--- a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry_header.xml
+++ b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_entry_header.xml
@@ -16,14 +16,16 @@
-->
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
- android:height="48dp"
+ android:minHeight="48dp"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:id="@+id/new_voicemail_header_text"
- style="@style/SecondaryText"
+ style="@style/SubHeader"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_marginStart="@dimen/voicemail_header_margin_start"
- android:layout_centerVertical="true"/>
+ android:layout_marginStart="16dp"
+ android:layout_marginTop="8dp"
+ android:layout_centerVertical="true"
+ android:layout_gravity="center_vertical"/>
</RelativeLayout>
diff --git a/java/com/android/dialer/voicemail/listui/res/values/dimens.xml b/java/com/android/dialer/voicemail/listui/res/values/dimens.xml
index e6fcb74f9..1fa308af8 100644
--- a/java/com/android/dialer/voicemail/listui/res/values/dimens.xml
+++ b/java/com/android/dialer/voicemail/listui/res/values/dimens.xml
@@ -17,19 +17,8 @@
<resources>
<!-- TODO(uabdullah): These values are to be shared with the call log entries -->
- <dimen name="call_log_entry_top_margin">6dp</dimen>
- <dimen name="call_log_entry_padding_bottom_end">16dp</dimen>
- <dimen name="call_log_entry_padding_top_start">12dp</dimen>
- <dimen name="call_log_entry_photo_size">48dp</dimen>
- <dimen name="call_log_entry_photo_padding">4dp</dimen>
- <dimen name="call_log_entry_photo_text_margin">8dp</dimen>
<dimen name="call_log_entry_menu_button_size">48dp</dimen>
-
<dimen name="voicemail_transcription_text_size">14sp</dimen>
-
- <dimen name="voicemail_icon_margin">12dp</dimen>
- <dimen name="voicemail_icon_size">16dp</dimen>
-
<dimen name="voicemail_playback_state_text_size">14sp</dimen>
<!-- TODO(uabdullah): Work with UX on this value to ensure proper spacing between
the seekbar and transcription -->
@@ -39,8 +28,6 @@
<dimen name="voicemail_media_player_height">56dp</dimen>
<dimen name="voicemail_media_player_width">0dp</dimen>
- <dimen name="voicemail_header_margin_start">16dp</dimen>
-
<dimen name="voicemail_tos_image_size">280dp</dimen>
<!-- Dimensions for voicemail alert -->