summaryrefslogtreecommitdiff
path: root/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml
diff options
context:
space:
mode:
authoruabdullah <uabdullah@google.com>2017-11-13 15:12:56 -0800
committerzachh <zachh@google.com>2017-11-18 04:21:53 +0000
commit85415fba82acabacef48e3c85355fa18e1f91f19 (patch)
treede7c3f8e91cef869f7415cedc565f3706bdc374e /java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml
parenta1c046f99a353985f41d2b0d9cecf31d53364ee6 (diff)
Add seekbar to Voicemail Media Player
Adds the UX support for showing the seekbar in the NUI Media player. It also shows a starting and total duration text as well, though as of right now it's a static value and will be updated in a follow up CL. Bug: 64882313,68382421,69268144 Test: Unit tests PiperOrigin-RevId: 175595293 Change-Id: I14440599d52352c213c7513dd2d0a8aef2f51bfe
Diffstat (limited to 'java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml')
-rw-r--r--java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml88
1 files changed, 70 insertions, 18 deletions
diff --git a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml
index 762782fb5..a21b6aa6c 100644
--- a/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml
+++ b/java/com/android/dialer/voicemail/listui/res/layout/new_voicemail_media_player_layout.xml
@@ -15,24 +15,76 @@
~ limitations under the License
-->
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:orientation="horizontal"
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
- android:layout_height="match_parent">
- <!-- TODO(a bug): Remove these buttons as this is a place holder for the Media Player -->
- <Button
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:text="Play"
- android:id="@+id/playButton" />
- <Button
- android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:paddingTop="@dimen/voicemail_media_player_padding_top"
+ android:orientation="vertical">
+
+ <!-- TODO(uabdullah): Make visibility gone (once implement fetching from vm server) -->
+ <TextView
+ android:id="@+id/playback_state_text"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:text="Speaker"
- android:id="@+id/speakerButton" />
- <Button
- android:layout_width="wrap_content"
+ android:gravity="center"
+ android:text="@string/voicemail_media_player_state"
+ android:textSize="@dimen/voicemail_playback_state_text_size"
+ android:visibility="gone"/>
+
+ <LinearLayout
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:text="Delete"
- android:id="@+id/deleteButton" />
-</LinearLayout>
+ android:gravity="center_vertical"
+ android:orientation="horizontal">
+
+ <TextView
+ android:id="@+id/playback_position_text"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:importantForAccessibility="no"
+ android:text="@string/voicemail_media_player_inital_start_position"
+ android:textSize="@dimen/voicemail_duration_size"/>
+
+ <!-- TODO(uabdullah): Add listener to seekbar -->
+ <SeekBar
+ android:id="@+id/playback_seek"
+ android:layout_width="0dp"
+ android:layout_height="wrap_content"
+ android:layout_weight="1"
+ android:max="0"
+ android:progress="0"/>
+
+ <!-- TODO(uabdullah): Remove android:text and replace with real value when binding -->
+ <TextView
+ android:id="@+id/playback_seek_total_duration"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:importantForAccessibility="no"
+ android:text="03:00"
+ android:textSize="@dimen/voicemail_duration_size"/>
+ </LinearLayout>
+
+ <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:paddingTop="10dp"
+ android:orientation="horizontal">
+ <!-- TODO(a bug): Remove these buttons as this is a place holder for the Media Player -->
+ <Button
+ android:id="@+id/playButton"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="Play"/>
+ <Button
+ android:id="@+id/speakerButton"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="Speaker"/>
+ <Button
+ android:id="@+id/deleteButton"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:text="Delete"/>
+ </LinearLayout>
+</LinearLayout> \ No newline at end of file