diff options
author | Dmitri Plotnikov <dplotnikov@google.com> | 2010-03-12 19:28:21 -0800 |
---|---|---|
committer | Dmitri Plotnikov <dplotnikov@google.com> | 2010-03-15 18:05:00 -0700 |
commit | 3b73d8b49e07b93b80a4f363a40c0680377f5225 (patch) | |
tree | 0b5ebebbd1e3dfe57577ef0f1242db8c9f8391a9 /res | |
parent | 67205edbef303f3e12cb6f9b46086f4dd0706606 (diff) | |
download | packages_apps_Contacts-3b73d8b49e07b93b80a4f363a40c0680377f5225.tar.gz packages_apps_Contacts-3b73d8b49e07b93b80a4f363a40c0680377f5225.tar.bz2 packages_apps_Contacts-3b73d8b49e07b93b80a4f363a40c0680377f5225.zip |
Implementing contact upgrade under low storage conditions.
Bug: 2498528
Change-Id: I2c85b0cbd4c7b804e61957695b803e22f995b405
Diffstat (limited to 'res')
-rw-r--r-- | res/layout-finger/contacts_list_content.xml | 18 | ||||
-rw-r--r-- | res/layout-finger/contacts_list_empty.xml | 64 | ||||
-rw-r--r-- | res/values/strings.xml | 14 |
3 files changed, 79 insertions, 17 deletions
diff --git a/res/layout-finger/contacts_list_content.xml b/res/layout-finger/contacts_list_content.xml index 2474975e8..36c03cef4 100644 --- a/res/layout-finger/contacts_list_content.xml +++ b/res/layout-finger/contacts_list_content.xml @@ -30,22 +30,6 @@ android:fastScrollEnabled="true" /> - <ScrollView android:id="@android:id/empty" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:fillViewport="true" - > - <TextView android:id="@+id/emptyText" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:text="@string/noContacts" - android:textSize="20sp" - android:textColor="?android:attr/textColorSecondary" - android:paddingLeft="10dip" - android:paddingRight="10dip" - android:paddingTop="10dip" - android:lineSpacingMultiplier="0.92" - /> - </ScrollView> + <include layout="@layout/contacts_list_empty"/> </LinearLayout> diff --git a/res/layout-finger/contacts_list_empty.xml b/res/layout-finger/contacts_list_empty.xml new file mode 100644 index 000000000..195da1ef3 --- /dev/null +++ b/res/layout-finger/contacts_list_empty.xml @@ -0,0 +1,64 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2010 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. +--> +<ScrollView + xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@android:id/empty" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:fillViewport="true" +> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical"> + + <TextView android:id="@+id/emptyText" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:text="@string/noContacts" + android:textSize="20sp" + android:textColor="?android:attr/textColorSecondary" + android:paddingLeft="10dip" + android:paddingRight="10dip" + android:paddingTop="10dip" + android:lineSpacingMultiplier="0.92" + /> + + <LinearLayout android:id="@+id/import_failure" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:gravity="fill_horizontal" + android:padding="20dip" + android:visibility="gone"> + + <Button + android:id="@+id/import_failure_uninstall_apps" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:textAppearance="?android:attr/textAppearanceMedium" + android:text="@string/upgrade_out_of_memory_uninstall"/> + + <Button + android:id="@+id/import_failure_retry_upgrade" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="10dip" + android:textAppearance="?android:attr/textAppearanceMedium" + android:text="@string/upgrade_out_of_memory_retry"/> + </LinearLayout> + </LinearLayout> +</ScrollView> diff --git a/res/values/strings.xml b/res/values/strings.xml index 38d63d017..39a2e18e4 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -1114,4 +1114,18 @@ <!-- Text shown in the contacts app while the background process updates contacts after a locale change --> <string name="locale_change_in_progress">Contact list is being updated to reflect the change of language.\n\nPlease wait...</string> + + <!-- Text shown in the contacts app while the background process updates contacts after a system upgrade --> + <string name="upgrade_in_progress">Contact list is being updated.\n\nPlease wait...</string> + + <!-- Text shown in the contacts app if the background process updating contacts fails because of memory shortage --> + <string name="upgrade_out_of_memory">Contacts are in the process of being upgraded. + \n\nThe upgrade process requires approximately <xliff:g id="size_in_megabytes">%d</xliff:g>Mb of + internal phone storage.\n\nChoose one of the following options:</string> + + <!-- Button shown in the contacts app if the background process updating contacts fails because of memory shortage --> + <string name="upgrade_out_of_memory_uninstall">Uninstall some applications</string> + + <!-- Button shown in the contacts app if the background process updating contacts fails because of memory shortage --> + <string name="upgrade_out_of_memory_retry">Retry upgrade</string> </resources> |