diff options
author | Isaac Katzenelson <isaack@android.com> | 2012-10-03 17:13:26 -0700 |
---|---|---|
committer | Isaac Katzenelson <isaack@android.com> | 2012-10-03 17:26:31 -0700 |
commit | 6b9508b70d9bb11590f96ef4ff6d5dfc703ac868 (patch) | |
tree | 32ead6593a4997fa4d26f5255ab227df9da77a65 /res | |
parent | 5c3795c271bc6160f0ae2056627e9e96ffdc335c (diff) | |
download | android_packages_apps_DeskClock-6b9508b70d9bb11590f96ef4ff6d5dfc703ac868.tar.gz android_packages_apps_DeskClock-6b9508b70d9bb11590f96ef4ff6d5dfc703ac868.tar.bz2 android_packages_apps_DeskClock-6b9508b70d9bb11590f96ef4ff6d5dfc703ac868.zip |
Move buttons to icons.
Bug: 7257710, 7238147
Converted all buttons to image buttons.
New layouts for timer to tie together the time display with the buttons
Change-Id: I0fbddd1050f98a1a2f1f542bef8cdfb80f005c23
Diffstat (limited to 'res')
-rw-r--r-- | res/layout-land/stopwatch_fragment.xml | 45 | ||||
-rw-r--r-- | res/layout-land/timer_list_item.xml | 25 | ||||
-rw-r--r-- | res/layout/clock_fragment.xml | 45 | ||||
-rw-r--r-- | res/layout/stopwatch_fragment.xml | 45 | ||||
-rw-r--r-- | res/layout/timer_fragment.xml | 7 | ||||
-rw-r--r-- | res/layout/timer_list_item.xml | 21 |
6 files changed, 92 insertions, 96 deletions
diff --git a/res/layout-land/stopwatch_fragment.xml b/res/layout-land/stopwatch_fragment.xml index 85d3e5a9c..37d9c641f 100644 --- a/res/layout-land/stopwatch_fragment.xml +++ b/res/layout-land/stopwatch_fragment.xml @@ -57,42 +57,37 @@ android:background="#28ffffff" /> <LinearLayout android:layout_width="match_parent" - android:layout_height="wrap_content" > - <Button + android:layout_height="48dip" > + <ImageButton android:id="@+id/stopwatch_left_button" - android:layout_width="0dip" - android:layout_weight="1" + android:layout_width="56dip" style="@style/button" + android:src="@drawable/ic_lap_normal" android:background="?android:attr/selectableItemBackground" - android:layout_height="wrap_content" /> - <View + android:layout_height="match_parent" /> + <Space android:layout_height="match_parent" - android:layout_marginTop="8dip" - android:layout_marginBottom="8dip" - android:layout_width="1dip" - android:background="#28ffffff" /> - <Button + android:layout_width="0dip" + android:layout_weight="1"/> + <ImageButton android:id="@+id/stopwatch_share_button" android:background="?android:attr/selectableItemBackground" - android:layout_width="0dip" - android:layout_weight="1" + android:src="@drawable/ic_share_normal" + android:layout_width="56dip" style="@style/button" - android:text="@string/sw_share_button" - android:layout_height="wrap_content" /> - <View - android:id="@+id/stopwatch_button_seperator" + android:contentDescription="@string/sw_share_button" + android:layout_height="match_parent" /> + <Space android:layout_height="match_parent" - android:layout_width="1dip" - android:layout_marginTop="8dip" - android:layout_marginBottom="8dip" - android:background="#28ffffff" /> - <Button + android:layout_width="0dip" + android:layout_weight="1"/> + <ImageButton android:id="@+id/stopwatch_right_button" android:background="?android:attr/selectableItemBackground" - android:layout_weight="1" - android:layout_width="0dip" + android:layout_width="56dip" + android:src="@drawable/ic_start_normal" style="@style/button" - android:layout_height="wrap_content" /> + android:layout_height="match_parent" /> </LinearLayout> </LinearLayout> diff --git a/res/layout-land/timer_list_item.xml b/res/layout-land/timer_list_item.xml index f1db09b60..3d3e1dccf 100644 --- a/res/layout-land/timer_list_item.xml +++ b/res/layout-land/timer_list_item.xml @@ -16,6 +16,7 @@ <!-- timer item in the list of active timers --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:gravity="center" android:layout_width="match_parent" android:layout_height="wrap_content"> @@ -37,33 +38,35 @@ android:layout_gravity="center"/> </FrameLayout> <LinearLayout - android:layout_width="0dip" + android:layout_width="48dip" android:layout_height="match_parent" - android:layout_weight="1" android:orientation="vertical"> - <Button + <ImageButton android:id="@+id/timer_delete" android:layout_width="match_parent" android:layout_weight="1" + android:src="@drawable/ic_delete_normal" style="@style/button" android:background="?android:attr/selectableItemBackground" - android:text="@string/timer_delete" - android:layout_height="0dip" /> - <Button + android:contentDescription="@string/timer_delete" + android:layout_height="48dip" /> + <ImageButton android:id="@+id/timer_plus_one" android:background="?android:attr/selectableItemBackground" android:layout_width="match_parent" android:layout_weight="1" + android:src="@drawable/ic_plusone_normal" style="@style/button" - android:text="@string/timer_plus_one" - android:layout_height="0dip" /> - <Button + android:contentDescription="@string/timer_plus_one" + android:layout_height="48dip" /> + <ImageButton android:id="@+id/timer_stop" android:background="?android:attr/selectableItemBackground" + android:src="@drawable/ic_stop_normal" android:layout_weight="1" android:layout_width="match_parent" - android:text="@string/timer_stop" + android:contentDescription="@string/timer_stop" style="@style/button" - android:layout_height="0dip" /> + android:layout_height="48dip" /> </LinearLayout> </LinearLayout> diff --git a/res/layout/clock_fragment.xml b/res/layout/clock_fragment.xml index 8a70e8f3d..b4b44cbe9 100644 --- a/res/layout/clock_fragment.xml +++ b/res/layout/clock_fragment.xml @@ -92,46 +92,45 @@ android:id="@+id/clock_buttons" android:gravity="bottom" android:layout_width="match_parent" - android:layout_height="wrap_content" > - <Button + android:layout_height="48dip" > + <ImageButton android:id="@+id/alarms_button" - android:text="@string/button_alarms" + android:contentDescription="@string/button_alarms" android:onClick="clockButtonsOnClick" - android:layout_width="0dip" - android:layout_weight="1" + android:layout_width="56dip" style="@style/button" + android:layout_gravity="left" + android:src="@drawable/ic_alarm" android:background="?android:attr/selectableItemBackground" - android:layout_height="wrap_content" /> - <View + android:layout_height="match_parent" /> + <Space android:layout_height="match_parent" - android:layout_marginTop="8dip" - android:layout_marginBottom="8dip" - android:layout_width="1dip" - android:background="#28ffffff" /> - <Button + android:layout_width="0dip" + android:layout_weight="1"/> + <ImageButton android:id="@+id/cities_button" - android:text="@string/button_cities" + android:contentDescription="@string/button_cities" android:onClick="clockButtonsOnClick" - android:layout_width="0dip" - android:layout_weight="1" + android:layout_width="56dip" + android:src="@drawable/ic_location" style="@style/button" + android:layout_gravity="center" android:background="?android:attr/selectableItemBackground" - android:layout_height="wrap_content" /> - <View + android:layout_height="match_parent" /> + <Space android:layout_height="match_parent" - android:layout_marginTop="8dip" - android:layout_marginBottom="8dip" - android:layout_width="1dip" - android:background="#28ffffff" /> + android:layout_width="0dip" + android:layout_weight="1"/> <ImageButton android:id="@+id/menu_button" android:contentDescription="@string/button_menu" style="?android:attr/actionOverflowButtonStyle" android:background="?android:attr/selectableItemBackground" android:onClick="clockButtonsOnClick" - android:minWidth="56dp" + android:layout_gravity="right" + android:width="56dip" android:layout_width="wrap_content" - android:layout_height="wrap_content" /> + android:layout_height="match_parent" /> </LinearLayout> </LinearLayout> </FrameLayout> diff --git a/res/layout/stopwatch_fragment.xml b/res/layout/stopwatch_fragment.xml index ef38d4beb..aa63f43fb 100644 --- a/res/layout/stopwatch_fragment.xml +++ b/res/layout/stopwatch_fragment.xml @@ -51,42 +51,37 @@ android:background="#28ffffff" /> <LinearLayout android:layout_width="match_parent" - android:layout_height="wrap_content" > - <Button + android:layout_height="48dip" > + <ImageButton android:id="@+id/stopwatch_left_button" - android:layout_width="0dip" - android:layout_weight="1" + android:layout_width="56dip" style="@style/button" + android:src="@drawable/ic_lap_normal" android:background="?android:attr/selectableItemBackground" - android:layout_height="wrap_content" /> - <View + android:layout_height="match_parent" /> + <Space android:layout_height="match_parent" - android:layout_marginTop="8dip" - android:layout_marginBottom="8dip" - android:layout_width="1dip" - android:background="#28ffffff" /> - <Button + android:layout_width="0dip" + android:layout_weight="1"/> + <ImageButton android:id="@+id/stopwatch_share_button" android:background="?android:attr/selectableItemBackground" - android:layout_width="0dip" - android:layout_weight="1" + android:src="@drawable/ic_share_normal" + android:layout_width="56dip" style="@style/button" - android:text="@string/sw_share_button" - android:layout_height="wrap_content" /> - <View - android:id="@+id/stopwatch_button_seperator" + android:contentDescription="@string/sw_share_button" + android:layout_height="match_parent" /> + <Space android:layout_height="match_parent" - android:layout_width="1dip" - android:layout_marginTop="8dip" - android:layout_marginBottom="8dip" - android:background="#28ffffff" /> - <Button + android:layout_width="0dip" + android:layout_weight="1"/> + <ImageButton android:id="@+id/stopwatch_right_button" android:background="?android:attr/selectableItemBackground" - android:layout_weight="1" - android:layout_width="0dip" + android:layout_width="56dip" + android:src="@drawable/ic_start_normal" style="@style/button" - android:layout_height="wrap_content" /> + android:layout_height="match_parent" /> </LinearLayout> </LinearLayout> diff --git a/res/layout/timer_fragment.xml b/res/layout/timer_fragment.xml index d5d06b8f2..b371923e9 100644 --- a/res/layout/timer_fragment.xml +++ b/res/layout/timer_fragment.xml @@ -36,13 +36,14 @@ android:layout_height="1dip" android:background="#28ffffff" /> - <Button + <ImageButton android:id="@+id/timer_add_timer" - android:text="@string/timer_add_timer" + android:contentDescription="@string/timer_add_timer" android:layout_width="match_parent" + android:src="@drawable/ic_add" style="@style/button" android:background="?android:attr/selectableItemBackground" - android:layout_height="wrap_content" /> + android:layout_height="48dip" /> </LinearLayout> <LinearLayout android:id="@+id/new_timer_page" diff --git a/res/layout/timer_list_item.xml b/res/layout/timer_list_item.xml index 98ee3c59c..b42fc272a 100644 --- a/res/layout/timer_list_item.xml +++ b/res/layout/timer_list_item.xml @@ -42,29 +42,32 @@ android:layout_height="wrap_content" android:paddingTop="12dp" android:paddingBottom="12dp" > - <Button + <ImageButton android:id="@+id/timer_delete" + android:src="@drawable/ic_delete_normal" android:layout_width="0dip" android:layout_weight="1" style="@style/button" android:background="?android:attr/selectableItemBackground" - android:text="@string/timer_delete" - android:layout_height="wrap_content" /> - <Button + android:contentDescription="@string/timer_delete" + android:layout_height="48dip" /> + <ImageButton android:id="@+id/timer_plus_one" + android:src="@drawable/ic_plusone_normal" android:background="?android:attr/selectableItemBackground" android:layout_width="0dip" android:layout_weight="1" style="@style/button" - android:text="@string/timer_plus_one" - android:layout_height="wrap_content" /> - <Button + android:contentDescription="@string/timer_plus_one" + android:layout_height="48dip" /> + <ImageButton android:id="@+id/timer_stop" + android:src="@drawable/ic_stop_normal" android:background="?android:attr/selectableItemBackground" android:layout_weight="1" android:layout_width="0dip" - android:text="@string/timer_stop" + android:contentDescription="@string/timer_stop" style="@style/button" - android:layout_height="wrap_content" /> + android:layout_height="48dip" /> </LinearLayout> </LinearLayout> |