summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
authorAndrew Lee <anwlee@google.com>2015-10-15 10:45:19 -0700
committerAndrew Lee <anwlee@google.com>2015-10-16 15:06:37 -0700
commitc412f94fb20db5cd177421e373fdf941e0135c81 (patch)
treea75f9138f6401c2704bf377ebdb1535347ad6603 /res
parent8d0847ca13ca46730756e1d3a3dff3d7d27fd18b (diff)
Add import for SEND_TO_VOICEMAIL.
+ Add utility class for async import functions. + Move check for contacts with SEND_TO_VOICEMAIl to util. + Add function for adding phone numbers of contacts with SEND_TO_VOICEMAIL to the block list, then clearing the SEND_TO_VOICEMAIL flag. + Fixed bug where the import text would not be shown for an empty block list. Rearranged layouts slightly to facilitate this. + Protect against null listeners in FilteredNumberAsyncQueryHandler. Bug: 23351616 Change-Id: Id526e16f20a3d28966bbc5e458cecfcd03ecb20f
Diffstat (limited to 'res')
-rw-r--r--res/layout/blocked_number_fragment.xml25
-rw-r--r--res/layout/blocked_number_header.xml9
-rw-r--r--res/values/strings.xml7
3 files changed, 20 insertions, 21 deletions
diff --git a/res/layout/blocked_number_fragment.xml b/res/layout/blocked_number_fragment.xml
index e86ccb596..bb4b7f20f 100644
--- a/res/layout/blocked_number_fragment.xml
+++ b/res/layout/blocked_number_fragment.xml
@@ -27,23 +27,22 @@
android:layout_height="wrap_content"
card_view:cardCornerRadius="0dp">
- <ListView android:id="@id/android:list"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:background="@color/background_dialer_white"
- android:layout_weight="1"
- android:drawSelectorOnTop="false"
- android:headerDividersEnabled="false" />
-
<LinearLayout
- android:id="@android:id/empty"
- android:layout_width="fill_parent"
- android:layout_height="fill_parent"
- android:orientation="vertical">
+ android:orientation="vertical"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:background="@color/background_dialer_white">
<include layout="@layout/blocked_number_header" />
- <TextView android:id="@id/android:empty"
+ <ListView android:id="@id/android:list"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:drawSelectorOnTop="false"
+ android:headerDividersEnabled="false" />
+
+ <TextView android:id="@android:id/empty"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingStart="@dimen/blocked_number_horizontal_margin"
diff --git a/res/layout/blocked_number_header.xml b/res/layout/blocked_number_header.xml
index 95880a7c0..39f532281 100644
--- a/res/layout/blocked_number_header.xml
+++ b/res/layout/blocked_number_header.xml
@@ -13,10 +13,7 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="wrap_content">
+<merge xmlns:android="http://schemas.android.com/apk/res/android">
<TextView android:id="@+id/textView"
android:layout_width="wrap_content"
@@ -26,7 +23,7 @@
android:padding="@dimen/blocked_number_container_padding"
style="@android:style/TextAppearance.Material.Subhead" />
- <RelativeLayout android:id="@+id/importsettings"
+ <RelativeLayout android:id="@+id/import_settings"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="gone">
@@ -77,4 +74,4 @@
android:layout_marginTop="8dp"
android:text="@string/blockNumber" />
-</LinearLayout>
+</merge>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index cd7ce8fa8..0b7d82c61 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -833,7 +833,7 @@
You previously marked some callers to be automatically sent to voicemail via other apps.
</string>
- <!-- Labe for button to view numbers of contacts previous marked to be sent to voicemail.
+ <!-- Label for button to view numbers of contacts previous marked to be sent to voicemail.
[CHAR_LIMIT=20] -->
<string name="blocked_call_settings_view_numbers_button">View Numbers</string>
@@ -841,6 +841,9 @@
list. [CHAR_LIMIT=20] -->
<string name="blocked_call_settings_import_button">Import</string>
+ <!-- Error toast message for when send to voicemail import fails. [CHAR LIMIT=40] -->
+ <string name="send_to_voicemail_import_failed">Import failed</string>
+
<!-- String describing the delete icon on a blocked number list item.
When tapped, it will show a dialog confirming the unblocking of the number.
[CHAR LIMIT=NONE]-->
@@ -853,7 +856,7 @@
<!-- Button to bring up UI to add a number to the blocked call list. [CHAR LIMIT=40] -->
<string name="blockNumber">Add number</string>
- <!-- Heading for the block list in the "Spam and blocked calls" settings. [CHAR LIMIT=64] -->
+ <!-- Heading for the block list in the "Spam and blocked cal)ls" settings. [CHAR LIMIT=64] -->
<string name="blockList">Block list</string>
<!-- Label for progress dialog when validating a number to be added to the block list.