summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorTyler Gunn <tgunn@google.com>2014-02-19 15:58:26 -0800
committerJay Shrauner <shrauner@google.com>2014-03-04 20:26:34 +0000
commit1a31e3439a23cb2c0ff4658e0bef2d3782825e72 (patch)
treee9006e114f3478535851d622a766c06bee4a93af /res
parent27c57f5ec6421d8de15214c09114266b4a917bed (diff)
downloadandroid_packages_apps_Dialer-1a31e3439a23cb2c0ff4658e0bef2d3782825e72.tar.gz
android_packages_apps_Dialer-1a31e3439a23cb2c0ff4658e0bef2d3782825e72.tar.bz2
android_packages_apps_Dialer-1a31e3439a23cb2c0ff4658e0bef2d3782825e72.zip
Adding "Speed Dial" title to dialer favorites list and moving "All Contacts" affordance.
Bug: 13080167 Change-Id: Id825ef4bfc9de5340d40cae8176bdc13fcfb3ccd (cherry picked from commit 9a06657538802e0100dc65c6ae0713c996298e1b)
Diffstat (limited to 'res')
-rw-r--r--res/drawable/background_favorites_menu.xml29
-rw-r--r--res/layout/phone_favorites_menu.xml58
-rw-r--r--res/values/colors.xml13
-rw-r--r--res/values/dimens.xml13
-rw-r--r--res/values/strings.xml18
5 files changed, 131 insertions, 0 deletions
diff --git a/res/drawable/background_favorites_menu.xml b/res/drawable/background_favorites_menu.xml
new file mode 100644
index 000000000..fc2669b10
--- /dev/null
+++ b/res/drawable/background_favorites_menu.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2014 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License
+ -->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:state_pressed="false">
+ <shape android:shape="rectangle" >
+ <solid android:color="@color/background_dialer_list_items" />
+ </shape>
+ </item>
+ <item android:state_pressed="true">
+ <shape android:shape="rectangle" >
+ <solid android:color="@color/favorites_menu_pressed_color" />
+ </shape>
+ </item>
+</selector> \ No newline at end of file
diff --git a/res/layout/phone_favorites_menu.xml b/res/layout/phone_favorites_menu.xml
new file mode 100644
index 000000000..d8f2f32c7
--- /dev/null
+++ b/res/layout/phone_favorites_menu.xml
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2014 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License
+ -->
+
+<!-- The phone favorites menu appears on the main dialer screen above the favorite callers area,
+ and provides access to the All Contacts list. -->
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/phone_favorites_menu"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:paddingLeft="@dimen/favorites_menu_margin"
+ android:paddingRight="@dimen/favorites_menu_margin"
+ android:paddingTop="@dimen/favorites_menu_margin"
+ android:paddingBottom="@dimen/favorites_menu_margin"
+ android:background="@drawable/background_favorites_menu"
+ android:addStatesFromChildren="true"
+ >
+ <TextView
+ android:layout_width="wrap_content"
+ android:layout_height="@dimen/favorites_menu_speed_dial_height"
+ android:fontFamily="@string/favorites_menu_speed_dial_font_family"
+ android:text="@string/favorites_menu_speed_dial"
+ android:textSize="@dimen/favorites_menu_speed_dial_text_size"
+ android:textColor="@color/speed_dial_text_color"
+ android:layout_alignParentLeft="true"
+ android:layout_centerVertical="true"
+ android:gravity="center"
+ />
+ <TextView
+ android:id="@+id/all_contacts_button"
+ android:fontFamily="@string/favorites_menu_all_contacts_font_family"
+ android:layout_width="wrap_content"
+ android:layout_height="@dimen/favorites_menu_all_contacts_height"
+ android:paddingLeft="@dimen/favorites_menu_padding"
+ android:paddingRight="@dimen/favorites_menu_padding"
+ android:text="@string/favorites_menu_all_contacts"
+ android:textSize="@dimen/favorites_menu_all_contacts_text_size"
+ android:background="@color/all_contacts_button_color"
+ android:textColor="@color/all_contacts_button_text_color"
+ android:layout_alignParentRight="true"
+ android:layout_centerVertical="true"
+ android:gravity="center"
+ android:focusable="true"
+ />
+</RelativeLayout> \ No newline at end of file
diff --git a/res/values/colors.xml b/res/values/colors.xml
index b2d4bc560..370bdfeb6 100644
--- a/res/values/colors.xml
+++ b/res/values/colors.xml
@@ -70,4 +70,17 @@
<!-- Text color for no favorites message -->
<color name="nofavorite_text_color">#777777</color>
+
+ <!-- Text color for the "speed dial" label in the favorites menu. -->
+ <color name="speed_dial_text_color">#555555</color>
+
+ <!-- Background color for the "All Contacts" button in the favorites menu. -->
+ <color name="all_contacts_button_color">#999999</color>
+
+ <!-- Background color for the favorites menu when pressed. -->
+ <color name="favorites_menu_pressed_color">#d6d6d6</color>
+
+ <!-- Text color for the "All Contacts" button above the favorite callers -->
+ <color name="all_contacts_button_text_color">#ffffff</color>
+
</resources>
diff --git a/res/values/dimens.xml b/res/values/dimens.xml
index 942698741..3c856d2e6 100644
--- a/res/values/dimens.xml
+++ b/res/values/dimens.xml
@@ -83,4 +83,17 @@
<!-- Padding for the tooltip -->
<dimen name="dismiss_button_padding_start">20dip</dimen>
<dimen name="dismiss_button_padding_end">28dip</dimen>
+
+ <!-- Margin around the favorites menu. -->
+ <dimen name="favorites_menu_margin">6dp</dimen>
+ <!-- Padding within the favorites menu. -->
+ <dimen name="favorites_menu_padding">4dp</dimen>
+ <!-- Text size for the "speed dial" text in the favorites menu. -->
+ <dimen name="favorites_menu_speed_dial_text_size">18sp</dimen>
+ <!-- Height of the speed dial TextView in the favorites menu. -->
+ <dimen name="favorites_menu_speed_dial_height">24dp</dimen>
+ <!-- Text size for the "All Contacts" text in the favorites menu. -->
+ <dimen name="favorites_menu_all_contacts_text_size">12sp</dimen>
+ <!-- Height of the all contacts Button in the favorites menu. -->
+ <dimen name="favorites_menu_all_contacts_height">24dp</dimen>
</resources>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index e84834113..2564cd7bd 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -719,4 +719,22 @@
<!-- Content description for dismiss button on badge. [CHAR LIMIT=NONE] -->
<string name="description_dismiss">Dismiss</string>
+
+ <!-- Header text displayed on the main dialer screen above the list of favorite phone numbers.
+ [CHAR LIMIT=21] -->
+ <string name="favorites_menu_speed_dial">Speed Dial</string>
+
+ <!-- Button text for the "all contacts" button displayed on the main dialer screen above the
+ list of favorite phone numbers. Navigates the user to the "All Contacts" list.
+ This text represents the same action as the text in string "menu_allContacts".
+ [CHAR LIMIT=21] -->
+ <string name="favorites_menu_all_contacts">ALL CONTACTS</string>
+
+ <!-- The font-family to use for the "speed dial" label on the favorites menu.
+ Do not translate. -->
+ <string name="favorites_menu_speed_dial_font_family">sans-serif-light</string>
+
+ <!-- The font-family to use for the "all contacts" label on the favorites menu.
+ Do not translate. -->
+ <string name="favorites_menu_all_contacts_font_family">sans-serif</string>
</resources>