summaryrefslogtreecommitdiffstats
path: root/res/layout
diff options
context:
space:
mode:
authorYorke Lee <yorkelee@google.com>2014-06-20 19:27:31 +0000
committerYorke Lee <yorkelee@google.com>2014-06-20 19:27:31 +0000
commit56444f96da37934839c788f2a74cbb5d8193c552 (patch)
tree67ce563c527882768a6a6bd8384814bdad933b77 /res/layout
parent8e7cebc6aff9b41192dd3348fc52ef62c06236ab (diff)
downloadandroid_packages_apps_ContactsCommon-56444f96da37934839c788f2a74cbb5d8193c552.tar.gz
android_packages_apps_ContactsCommon-56444f96da37934839c788f2a74cbb5d8193c552.tar.bz2
android_packages_apps_ContactsCommon-56444f96da37934839c788f2a74cbb5d8193c552.zip
Revert "Update Emergency Dialer to match Dialer (3/5)."
This reverts commit 8e7cebc6aff9b41192dd3348fc52ef62c06236ab. Change-Id: Ifa42f45868286b80e111229bb0761798af884293
Diffstat (limited to 'res/layout')
-rw-r--r--res/layout/dialpad.xml111
-rw-r--r--res/layout/dialpad_key.xml35
-rw-r--r--res/layout/dialpad_key_one.xml41
-rw-r--r--res/layout/dialpad_view.xml94
4 files changed, 281 insertions, 0 deletions
diff --git a/res/layout/dialpad.xml b/res/layout/dialpad.xml
new file mode 100644
index 00000000..90cbe184
--- /dev/null
+++ b/res/layout/dialpad.xml
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2006 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.
+-->
+
+<!-- Dialpad in the Phone app. -->
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/dialpad"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical"
+ android:clipChildren="false">
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="0dp"
+ android:layout_weight="1"
+ android:orientation="horizontal">
+ <Space style="@style/DialpadSpaceStyle" />
+ <include layout="@layout/dialpad_key_one" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/two"
+ style="@style/DialpadKeyButtonStyle" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/three"
+ style="@style/DialpadKeyButtonStyle" />
+ <Space style="@style/DialpadSpaceStyle" />
+ </LinearLayout>
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="0dp"
+ android:layout_weight="1"
+ android:orientation="horizontal">
+ <Space style="@style/DialpadSpaceStyle" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/four"
+ style="@style/DialpadKeyButtonStyle" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/five"
+ style="@style/DialpadKeyButtonStyle" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/six"
+ style="@style/DialpadKeyButtonStyle" />
+ <Space style="@style/DialpadSpaceStyle" />
+ </LinearLayout>
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="0dp"
+ android:layout_weight="1"
+ android:orientation="horizontal">
+ <Space style="@style/DialpadSpaceStyle" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/seven"
+ style="@style/DialpadKeyButtonStyle" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/eight"
+ style="@style/DialpadKeyButtonStyle" />
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/nine"
+ style="@style/DialpadKeyButtonStyle" />
+ <Space style="@style/DialpadSpaceStyle" />
+ </LinearLayout>
+
+ <LinearLayout
+ android:layout_width="match_parent"
+ android:layout_height="0dp"
+ android:layout_weight="1"
+ android:orientation="horizontal">
+ <Space style="@style/DialpadSpaceStyle" />
+ <com.android.contacts.common.dialpad.DialpadKeyButton
+ android:id="@+id/star"
+ style="@style/DialpadKeyButtonStyle">
+ <LinearLayout
+ style="@style/DialpadKeyInternalLayoutStyle">
+ <com.android.contacts.common.dialpad.DialpadTextView
+ android:id="@+id/dialpad_key_number"
+ style="@style/DialpadKeyStarStyle" />
+ </LinearLayout>
+ </com.android.contacts.common.dialpad.DialpadKeyButton>
+ <include layout="@layout/dialpad_key"
+ android:id="@+id/zero"
+ style="@style/DialpadKeyButtonStyle" />
+ <com.android.contacts.common.dialpad.DialpadKeyButton
+ android:id="@+id/pound"
+ style="@style/DialpadKeyButtonStyle">
+ <LinearLayout
+ style="@style/DialpadKeyInternalLayoutStyle">
+ <com.android.contacts.common.dialpad.DialpadTextView
+ android:id="@id/dialpad_key_number"
+ style="@style/DialpadKeyPoundStyle" />
+ </LinearLayout>
+ </com.android.contacts.common.dialpad.DialpadKeyButton>
+ <Space style="@style/DialpadSpaceStyle" />
+ </LinearLayout>
+ <Space
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/dialpad_bottom_key_height" />
+</LinearLayout>
diff --git a/res/layout/dialpad_key.xml b/res/layout/dialpad_key.xml
new file mode 100644
index 00000000..1d2d55a5
--- /dev/null
+++ b/res/layout/dialpad_key.xml
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2013 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.
+-->
+
+<!-- A layout representing a single key in the dialpad -->
+<com.android.contacts.common.dialpad.DialpadKeyButton
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ style="@style/DialpadKeyButtonStyle" >
+
+ <LinearLayout style="@style/DialpadKeyInternalLayoutStyle">
+
+ <!-- Note in the referenced styles that we assign hard widths to these components
+ because we want them to line up vertically when we arrange them in an MxN grid -->
+
+ <com.android.contacts.common.dialpad.DialpadTextView
+ android:id="@+id/dialpad_key_number"
+ style="@style/DialpadKeyNumberStyle" />
+
+ <TextView
+ android:id="@+id/dialpad_key_letters"
+ style="@style/DialpadKeyLettersStyle" />
+ </LinearLayout>
+</com.android.contacts.common.dialpad.DialpadKeyButton> \ No newline at end of file
diff --git a/res/layout/dialpad_key_one.xml b/res/layout/dialpad_key_one.xml
new file mode 100644
index 00000000..2365e6ef
--- /dev/null
+++ b/res/layout/dialpad_key_one.xml
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2006 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.
+-->
+<com.android.contacts.common.dialpad.DialpadKeyButton
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/one"
+ style="@style/DialpadKeyButtonStyle">
+ <LinearLayout
+ style="@style/DialpadKeyInternalLayoutStyle">
+ <com.android.contacts.common.dialpad.DialpadTextView
+ android:id="@+id/dialpad_key_number"
+ style="@style/DialpadKeyNumberStyle" />
+ <RelativeLayout
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content" >
+ <ImageView
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:paddingTop="@dimen/dialpad_voicemail_icon_padding_top"
+ android:id="@+id/dialpad_key_voicemail"
+ android:src="@drawable/ic_dialpad_vm"
+ android:scaleType="fitCenter"
+ android:layout_centerInParent="true"
+ android:tint="@color/dialpad_secondary_text_color" />
+ <!-- Place empty text view so vertical height is same as other dialpad keys. -->
+ <TextView style="@style/DialpadKeyLettersStyle" />
+ </RelativeLayout>
+ </LinearLayout>
+</com.android.contacts.common.dialpad.DialpadKeyButton>
diff --git a/res/layout/dialpad_view.xml b/res/layout/dialpad_view.xml
new file mode 100644
index 00000000..7dfbff67
--- /dev/null
+++ b/res/layout/dialpad_view.xml
@@ -0,0 +1,94 @@
+<?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.
+-->
+<view class="com.android.contacts.common.dialpad.DialpadView"
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/dialpad_view"
+ android:layout_height="match_parent"
+ android:layout_width="match_parent"
+ android:layout_gravity="bottom"
+ android:orientation="vertical"
+ android:layoutDirection="ltr"
+ android:background="@color/background_dialpad"
+ android:clickable="true" >
+
+ <!-- Text field and possibly soft menu button above the keypad where
+ the digits are displayed. -->
+ <LinearLayout
+ android:id="@+id/digits_container"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/dialpad_digits_height"
+ android:orientation="horizontal">
+
+ <ImageButton android:id="@+id/dialpad_overflow"
+ android:background="@drawable/btn_dialpad_key"
+ android:src="@drawable/ic_overflow_menu"
+ android:tint="@color/dialpad_icon_tint"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:paddingLeft="@dimen/dialpad_digits_padding"
+ android:paddingRight="@dimen/dialpad_digits_menu_right_padding"
+ android:contentDescription="@string/description_dialpad_overflow"
+ android:gravity="center"
+ android:visibility="gone" />
+
+ <view class="com.android.contacts.common.dialpad.DigitsEditText"
+ android:id="@+id/digits"
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:scrollHorizontally="true"
+ android:singleLine="true"
+ android:layout_weight="1"
+ android:gravity="center"
+ android:background="@android:color/transparent"
+ android:maxLines="1"
+ android:textSize="@dimen/dialpad_digits_text_size"
+ android:freezesText="true"
+ android:focusableInTouchMode="true"
+ android:cursorVisible="false"
+ android:textColor="@color/dialpad_digits_text_color"
+ android:textCursorDrawable="@null"
+ android:fontFamily="sans-serif-light"
+ android:textStyle="normal" />
+
+ <ImageButton
+ android:id="@+id/deleteButton"
+ android:background="@drawable/btn_dialpad_key"
+ android:tint="@color/dialpad_icon_tint"
+ android:paddingLeft="@dimen/dialpad_digits_padding"
+ android:paddingRight="@dimen/dialpad_digits_padding"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:state_enabled="false"
+ android:contentDescription="@string/description_delete_button"
+ android:src="@drawable/ic_dialpad_delete" />
+ </LinearLayout>
+
+ <View
+ android:layout_width="match_parent"
+ android:layout_height="1dp"
+ android:background="#e3e3e3" />
+
+ <Space
+ android:layout_width="match_parent"
+ android:layout_height="14dp" />
+
+ <include layout="@layout/dialpad" />
+
+ <Space
+ android:layout_width="match_parent"
+ android:layout_height="8dp" />
+
+</view>