Improve CAF strings

- Move them to cm_strings
- Delete unused ones
- Improve wording

Change-Id: I41b65c4ddcfd36f4e4ef7f622b0e74b5ffb8bae2
(cherry picked from commit f5f814b58fdb508e7c8930bdeeb0a467a1f06d3d)
diff --git a/res/values-ast-rES/strings.xml b/res/values-ast-rES/strings.xml
index 837c3e9..6e44e67 100644
--- a/res/values-ast-rES/strings.xml
+++ b/res/values-ast-rES/strings.xml
@@ -562,9 +562,6 @@
   <string name="contact_status_update_attribution">per aciu de <xliff:g id="source" example="Google Talk">%1$s</xliff:g></string>
   <!-- Attribution of a contact status update, when the time of update is known -->
   <string name="contact_status_update_attribution_with_date"><xliff:g id="date" example="3 hours ago">%1$s</xliff:g> per aciu de <xliff:g id="source" example="Google Talk">%2$s</xliff:g></string>
-  <!-- Message while reading multiple vCard files "(current number) of (total number) files"
-          The order of "current number" and "total number" cannot be changed -->
-  <string name="progressdialog_cancel">Encaboxar</string>
   <!-- Dialog title shown when (USB) storage does not exist [CHAR LIMIT=25] -->
   <!-- Dialog title shown when SD Card does not exist -->
   <!-- Confirmation dialog title after users selects to delete a contact. [CHAR LIMIT=25]-->
diff --git a/res/values-ku/strings.xml b/res/values-ku/strings.xml
index 759d81d..a1558dc 100644
--- a/res/values-ku/strings.xml
+++ b/res/values-ku/strings.xml
@@ -545,9 +545,6 @@
   <string name="contact_status_update_attribution">له‌لایه‌ن <xliff:g id="source" example="Google Talk">%1$s</xliff:g></string>
   <!-- Attribution of a contact status update, when the time of update is known -->
   <string name="contact_status_update_attribution_with_date"><xliff:g id="date" example="3 hours ago">%1$s</xliff:g> له‌ڕێگه‌ی <xliff:g id="source" example="Google Talk">%2$s</xliff:g></string>
-  <!-- Message while reading multiple vCard files "(current number) of (total number) files"
-          The order of "current number" and "total number" cannot be changed -->
-  <string name="progressdialog_cancel">هەڵوەشاندنەوە</string>
   <!-- Dialog title shown when (USB) storage does not exist [CHAR LIMIT=25] -->
   <!-- Dialog title shown when SD Card does not exist -->
   <!-- Confirmation dialog title after users selects to delete a contact. [CHAR LIMIT=25]-->
diff --git a/res/values-lb/strings.xml b/res/values-lb/strings.xml
index f63ab66..ffc790a 100644
--- a/res/values-lb/strings.xml
+++ b/res/values-lb/strings.xml
@@ -552,9 +552,6 @@
   <string name="contact_status_update_attribution">iwwer <xliff:g id="source" example="Google Talk">%1$s</xliff:g></string>
   <!-- Attribution of a contact status update, when the time of update is known -->
   <string name="contact_status_update_attribution_with_date"><xliff:g id="date" example="3 hours ago">%1$s</xliff:g> iwwer <xliff:g id="source" example="Google Talk">%2$s</xliff:g></string>
-  <!-- Message while reading multiple vCard files "(current number) of (total number) files"
-          The order of "current number" and "total number" cannot be changed -->
-  <string name="progressdialog_cancel">Ofbriechen</string>
   <!-- Dialog title shown when (USB) storage does not exist [CHAR LIMIT=25] -->
   <!-- Dialog title shown when SD Card does not exist -->
   <!-- Confirmation dialog title after users selects to delete a contact. [CHAR LIMIT=25]-->
diff --git a/res/values-ug/strings.xml b/res/values-ug/strings.xml
index 8752c05..6d0cb28 100644
--- a/res/values-ug/strings.xml
+++ b/res/values-ug/strings.xml
@@ -537,9 +537,6 @@
   <string name="contact_status_update_attribution">via <xliff:g id="source" example="Google Talk">%1$s</xliff:g></string>
   <!-- Attribution of a contact status update, when the time of update is known -->
   <string name="contact_status_update_attribution_with_date"><xliff:g id="source" example="Google Talk">%2$s</xliff:g> ئارقىلىق <xliff:g id="date" example="3 hours ago">%1$s</xliff:g></string>
-  <!-- Message while reading multiple vCard files "(current number) of (total number) files"
-          The order of "current number" and "total number" cannot be changed -->
-  <string name="progressdialog_cancel">ۋاز كەچ</string>
   <!-- Dialog title shown when (USB) storage does not exist [CHAR LIMIT=25] -->
   <!-- Dialog title shown when SD Card does not exist -->
   <!-- Confirmation dialog title after users selects to delete a contact. [CHAR LIMIT=25]-->
diff --git a/res/values-zh-rCN/strings.xml b/res/values-zh-rCN/strings.xml
index d3e2e94..dee67a6 100755
--- a/res/values-zh-rCN/strings.xml
+++ b/res/values-zh-rCN/strings.xml
@@ -165,11 +165,8 @@
     <string name="listCustomView" msgid="1915154113477432033">"自定义视图中的联系人"</string>
     <string name="listSingleContact" msgid="8525131203887307088">"单个联系人"</string>
     <string name="dialog_new_contact_account" msgid="4107520273478326011">"在以下帐户中创建联系人:"</string>
-    <string name="export_to_sim">"导出到 SIM 卡"</string>
-    <string name="import_from_sim" msgid="4749894687871835873">"从 SIM 卡导入"</string>
     <string name="import_from_sim_summary" msgid="2306434118233541675">"从 SIM 卡“<xliff:g id="SIM_NAME">^1</xliff:g>” - <xliff:g id="SIM_NUMBER">^2</xliff:g> 导入"</string>
     <string name="import_from_sim_summary_no_number" msgid="8498561004799710237">"从 SIM 卡“<xliff:g id="SIM_NAME">%1$s</xliff:g>”导入"</string>
-    <string name="export_to_sim">"导出到 SIM 卡"</string>
     <string name="import_from_vcf_file" product="default" msgid="1381675161522633950">"从 .vcf 文件导入"</string>
     <string name="cancel_import_confirmation_message" msgid="7764915400478970495">"要取消导入“<xliff:g id="FILENAME">%s</xliff:g>”吗?"</string>
     <string name="cancel_export_confirmation_message" msgid="4063783315931861656">"要取消导出“<xliff:g id="FILENAME">%s</xliff:g>”吗?"</string>
@@ -241,8 +238,6 @@
 
     <string name="no_contact_to_share" msgid="5749367538191552509">"没有可供分享的联系人。"</string>
 
-    <string name="share_failed">"联系人太多,分享失败。"</string>
-
     <string name="menu_search" msgid="7464453023659824700">"搜索"</string>
     <string name="menu_contacts_filter" msgid="586356478145511794">"要显示的联系人"</string>
     <string name="activity_title_contacts_filter" msgid="7689519428197855166">"要显示的联系人"</string>
@@ -260,28 +255,6 @@
     <string name="contact_status_update_attribution" msgid="8419168578670128134">"来源:<xliff:g id="SOURCE">%1$s</xliff:g>"</string>
     <string name="contact_status_update_attribution_with_date" msgid="7492465535645607473">"<xliff:g id="DATE">%1$s</xliff:g>,来源:<xliff:g id="SOURCE">%2$s</xliff:g>"</string>
     <string name="action_menu_back_from_search" msgid="1138551123844019647">"停止搜索"</string>
-    <string name="exporting">"正在导出"</string>
-    <string name="reading_vcard_files">读取VCARD文件</string>
-    <string name="progressdialog_cancel">取消</string>
-    <string name="export_to_sim_failed">"导出失败,<xliff:g id="insertCount">%d</xliff:g>条成功导出"</string>
-    <string name="export_sim_card_full">"SIM卡已满,<xliff:g id="insertCount">%d</xliff:g>条成功导出"</string>
-    <string name="export_finished">"导出结束"</string>
-    <string name="tag_too_long">"发生错误,联系人姓名过长。"</string>
-    <string name="sim_contacts_not_load">发生错误,SIM卡联系人未完全加载</string>
-    <string name="export_cancelled">导出操作被取消,<xliff:g id="insertCount">%s</xliff:g>条成功导出</string>
-    <string name="export_no_phone_or_email">导出失败, <xliff:g id="name">%s</xliff:g>没有电话号码或者邮箱地址</string>
-    <string name="import_from_sim_select">"选择SIM卡进行导入"</string>
-    <string name="no_sdcard_title" product="nosdcard">"存储设备不存在"</string>
-    <string name="no_sdcard_title" product="default">"无 SD 卡"</string>
-    <string name="deleteConfirmation_title">"要删除联系人吗?"</string>
-    <string name="deleteConfirmation">"将会删除此联系人。"</string>
-    <string name="slot_name">"卡"</string>
-    <string name="copy_done">复制成功!</string>
-    <string name="copy_failure">复制失败!</string>
-    <string name="card_no_space">卡记录已满,部分信息未复制</string>
-    <string name="select_path">请选择路径</string>
-    <string name="sd_card">SD 卡</string>
-    <string name="phone_storage">手机内存</string>
     <string name="description_clear_search" msgid="3893511425518852086">"清除搜索内容"</string>
     <string name="settings_contact_display_options_title" msgid="1020420603072835628">"联系人显示选项"</string>
     <string name="select_account_dialog_title" msgid="5509088895267310568">"帐号"</string>
diff --git a/res/values-zh-rTW/strings.xml b/res/values-zh-rTW/strings.xml
index 36e290d..22a25b3 100755
--- a/res/values-zh-rTW/strings.xml
+++ b/res/values-zh-rTW/strings.xml
@@ -165,7 +165,6 @@
     <string name="listCustomView" msgid="1915154113477432033">"聯絡人自訂檢視"</string>
     <string name="listSingleContact" msgid="8525131203887307088">"單一聯絡人"</string>
     <string name="dialog_new_contact_account" msgid="4107520273478326011">"在帳戶下建立聯絡人"</string>
-    <string name="export_to_sim">"導出到 SIM 卡"</string>
     <string name="import_from_sim" msgid="4749894687871835873">"從 SIM 卡匯入"</string>
     <string name="import_from_sim_summary" msgid="2306434118233541675">"從 SIM 卡 <xliff:g id="SIM_NAME">^1</xliff:g> - <xliff:g id="SIM_NUMBER">^2</xliff:g> 匯入"</string>
     <string name="import_from_sim_summary_no_number" msgid="8498561004799710237">"從 SIM 卡 <xliff:g id="SIM_NAME">%1$s</xliff:g> 匯入"</string>
@@ -257,24 +256,6 @@
     <string name="action_menu_back_from_search" msgid="1138551123844019647">"停止搜尋"</string>
     <string name="description_clear_search" msgid="3893511425518852086">"清除搜尋"</string>
     <string name="settings_contact_display_options_title" msgid="1020420603072835628">"聯絡人顯示選項"</string>
-    <string name="settings_contact_display_options_description" msgid="4130259058302284077">"設定聯絡人的顯示和排序方式。"</string>
-    <string name="exporting">"正在導出"</string>
-    <string name="reading_vcard_files">讀取Vcard文件</string>
-    <string name="export_to_sim_failed">"導出失敗,<xliff:g id="insertCount">%d</xliff:g>條成功導出"</string>
-    <string name="export_sim_card_full">"SIM卡已滿,<xliff:g id="insertCount">%d</xliff:g>條成功導出"</string>
-    <string name="export_finished">"導出結束"</string>
-    <string name="export_no_phone_or_email">導出失敗, <xliff:g id="name">%s</xliff:g>沒有電話號碼或者郵箱地址</string>
-    <string name="tag_too_long">"發生錯誤,聯絡人姓名過長。"</string>
-    <string name="import_from_sim_select">"選擇SIM卡進行導入"</string>
-    <string name="no_sdcard_title" product="nosdcard">"無存儲設備"</string>
-    <string name="no_sdcard_title" product="default">"無 SD 卡"</string>
-    <string name="deleteConfirmation_title">"要刪除聯絡人嗎?"</string>
-    <string name="ContactMultiDeleteConfirmation">"將會刪除這些聯絡人。"</string>
-    <string name="slot_name">"卡"</string>
-
-    <string name="copy_done">複制成功!</string>
-    <string name="copy_failure">複制失敗!</string>
-    <string name="card_no_space">卡記錄已滿,部分信息未複制</string>
     <string name="select_account_dialog_title" msgid="5509088895267310568">"帳戶"</string>
     <string name="set_default_account" msgid="3865970860434642695">"一律使用這張 SIM 卡通話"</string>
     <string name="select_phone_account_for_calls" msgid="933905607702811164">"選擇通話帳戶"</string>
diff --git a/res/values/cm_strings.xml b/res/values/cm_strings.xml
new file mode 100644
index 0000000..3d55452
--- /dev/null
+++ b/res/values/cm_strings.xml
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+     Copyright (c) 2011-2013, The Linux Foundation. All rights reserved.
+     Copyright (C) 2017 The LineageOS 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.
+-->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <!-- Action that exports all contacts to SIM -->
+    <string name="export_to_sim">Export to SIM card</string>
+
+    <!-- Action string for selecting (USB) storage for importing contacts [CHAR LIMIT=30] -->
+    <string name="import_from_sdcard" product="default">Import from storage</string>
+
+    <!-- Action that exports all contacts to (USB) storage [CHAR LIMIT=25] -->
+    <string name="export_to_sdcard" product="default">Export to storage</string>
+
+    <!-- Toast indicating that sharing too many contact has failed. [CHAR LIMIT=NONE]  -->
+    <string name="share_failed">Too many contacts, share failed</string>
+
+    <string name="label_groups">Group</string>
+    <string name="exporting">Exporting\u2026</string>
+
+    <!-- Message while reading multiple vCard files "(current number) of (total number) files"
+         The order of "current number" and "total number" cannot be changed -->
+    <string name="reading_vcard_files"><xliff:g id="current_number">%1$s</xliff:g> of <xliff:g id="total_number">%2$s</xliff:g> files</string>
+
+    <string name="export_to_sim_failed">Export failed, <xliff:g id="insertCount">%d</xliff:g> items were exported</string>
+
+    <string name="sim_contact_export_failed">Export of contact failed (name: <xliff:g id="name">%1$s</xliff:g>, number: <xliff:g id="number">%2$s</xliff:g>, email: <xliff:g id="email">%3$s</xliff:g>)</string>
+
+    <string name="export_sim_card_full">SIM card is full, <xliff:g id="insertCount">%d</xliff:g> items were exported</string>
+
+    <string name="export_failed">Export failed</string>
+
+    <string name="sim_card_full">SIM card is full</string>
+
+    <string name="export_finished">Export finished</string>
+
+    <string name="tag_too_long">Contact name is too long</string>
+
+    <string name="sim_contacts_not_loaded">Unable to load SIM contacts</string>
+
+    <string name="export_cancelled">Export was canceled, <xliff:g id="insertCount">%s</xliff:g> items were exported</string>
+
+    <string name="export_no_phone_or_email"><xliff:g id="name">%s</xliff:g>has not phone number or email address</string>
+
+    <string name="import_from_sim_select">Choose card to import</string>
+
+    <!-- Dialog title shown when (USB) storage does not exist [CHAR LIMIT=25] -->
+    <string name="no_sdcard_title" product="nosdcard">Storage unavailable</string>
+    <!-- Dialog title shown when SD Card does not exist -->
+    <string name="no_sdcard_title" product="default">No SD card</string>
+
+    <!-- Confirmation dialog title after users selects to delete a contact. [CHAR LIMIT=25]-->
+    <string name="deleteConfirmation_title">Delete contact?</string>
+
+    <!-- Confirmation dialog contents after users selects to delete a Writable contact. -->
+    <string name="deleteConfirmation">This contact will be deleted.</string>
+
+    <string name="copy_done">Contact was copied successfully</string>
+    <string name="copy_failure">Copying the contact failed</string>
+    <string name="card_no_space">Copying the contact failed, SIM card is full</string>
+</resources>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index 4d2a0a1..fea5926 100755
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -432,15 +432,6 @@
     <!-- Action string for selecting SIM for importing contacts -->
     <string name="import_from_sim">Import from SIM card</string>
 
-    <!-- Action that exports all contacts to SIM -->
-    <string name="export_to_sim">Export to SIM card</string>
-    <!-- Action string for selecting SIM for importing contacts -->
-    <string name="import_from_sim">Import from SIM card</string>
-
-    <!-- Action string for selecting (USB) storage for importing contacts [CHAR LIMIT=30] -->
-    <string name="import_from_sdcard" product="default">Import from storage</string>
-
-
     <!-- Action string for selecting a SIM subscription for importing contacts -->
     <string name="import_from_sim_summary">Import from SIM <xliff:g id="sim_name">^1</xliff:g> - <xliff:g id="sim_number">^2</xliff:g></string>
 
@@ -638,9 +629,6 @@
     <!-- Action that exports all contacts to a user selected destination. [CHAR LIMIT=25] -->
     <string name="export_to_vcf_file" product="default">Export to .vcf file</string>
 
-        <!-- Action that exports all contacts to (USB) storage [CHAR LIMIT=25] -->
-    <string name="export_to_sdcard" product="default">Export to storage</string>
-
     <!-- Contact preferences related strings -->
 
     <!-- Label of the "sort by" display option -->
@@ -704,10 +692,6 @@
     <!-- Toast indicating that no visible contact to share [CHAR LIMIT=NONE]  -->
     <string name="no_contact_to_share">There are no contacts to share.</string>
 
-
-    <!-- Toast indicating that sharing too many contact has failed. [CHAR LIMIT=NONE]  -->
-    <string name="share_failed">Too many contacts, share failed</string>
-
     <!-- Menu item to search contacts -->
     <string name="menu_search">Search</string>
 
@@ -765,54 +749,6 @@
     <!-- Attribution of a contact status update, when the time of update is known -->
     <string name="contact_status_update_attribution_with_date"><xliff:g id="date" example="3 hours ago">%1$s</xliff:g> via <xliff:g id="source" example="Google Talk">%2$s</xliff:g></string>
 
-    <string name="label_groups">Group</string>
-
-    <string name="exporting">Exporting</string>
-
-    <!-- Message while reading multiple vCard files "(current number) of (total number) files"
-          The order of "current number" and "total number" cannot be changed -->
-    <string name="reading_vcard_files"><xliff:g id="current_number">%1$s</xliff:g> of <xliff:g id="total_number">%2$s</xliff:g> files</string>
-
-    <string name="progressdialog_cancel">Cancel</string>
-
-    <string name="export_to_sim_failed">Export failed, <xliff:g id="insertCount">%d</xliff:g> items are exported</string>
-
-    <string name="sim_contact_export_failed">Export failed, Contact name: <xliff:g id="name">%1$s</xliff:g>, number: <xliff:g id="number">%2$s</xliff:g>, email: <xliff:g id="email">%3$s</xliff:g></string>
-
-    <string name="export_sim_card_full">Sim Card is full, <xliff:g id="insertCount">%d</xliff:g> items are exported</string>
-
-    <string name="export_failed">Export failed</string>
-
-    <string name="sim_card_full">Error, Sim Card is full.</string>
-
-    <string name="export_finished">Export finished</string>
-
-    <string name="tag_too_long">Error, Contact name is too long.</string>
-
-    <string name="sim_contacts_not_load">Error, SIM contacts have not been loaded completely.</string>
-
-    <string name="export_cancelled">Export is canceled, <xliff:g id="insertCount">%s</xliff:g>items are exported</string>
-
-    <string name="export_no_phone_or_email">Export failed, <xliff:g id="name">%s</xliff:g>has not phone number or
-         email address</string>
-
-    <string name="import_from_sim_select">Choose card to import</string>
-
-    <!-- Dialog title shown when (USB) storage does not exist [CHAR LIMIT=25] -->
-    <string name="no_sdcard_title" product="nosdcard">Storage unavailable</string>
-    <!-- Dialog title shown when SD Card does not exist -->
-    <string name="no_sdcard_title" product="default">No SD card</string>
-        <!-- Confirmation dialog title after users selects to delete a contact. [CHAR LIMIT=25]-->
-    <string name="deleteConfirmation_title">Delete contact?</string>
-
-    <!-- Confirmation dialog contents after users selects to delete a Writable contact. -->
-    <string name="deleteConfirmation">This contact will be deleted.</string>
-        <!-- The slot common name -->
-    <string name="slot_name">SIM</string>
-
-    <string name="copy_done">Copy done!</string>
-    <string name="copy_failure">Copy Failed!</string>
-    <string name="card_no_space">Card has no space ,some record copy failed</string>
     <!-- Font family used when drawing letters for letter tile avatars.
          Do not translate. -->
     <string name="letter_tile_letter_font_family">sans-serif-medium</string>
diff --git a/src/com/android/contacts/common/interactions/ImportExportDialogFragment.java b/src/com/android/contacts/common/interactions/ImportExportDialogFragment.java
index 880411f..1a8359a 100755
--- a/src/com/android/contacts/common/interactions/ImportExportDialogFragment.java
+++ b/src/com/android/contacts/common/interactions/ImportExportDialogFragment.java
@@ -875,7 +875,7 @@
                     break;
                 case TOAST_SIM_CARD_NOT_LOAD_COMPLETE:
                     Toast.makeText(mPeople,
-                            R.string.sim_contacts_not_load, Toast.LENGTH_SHORT)
+                            R.string.sim_contacts_not_loaded, Toast.LENGTH_SHORT)
                             .show();
                     break;
                 case TOAST_SIM_EXPORT_FAILED:
@@ -916,7 +916,7 @@
 
             // add a cancel button to let user cancel explicitly.
             mExportProgressDlg.setButton(DialogInterface.BUTTON_NEGATIVE,
-                mPeople.getString(R.string.progressdialog_cancel),
+                mPeople.getString(android.R.string.cancel),
                     new DialogInterface.OnClickListener() {
                         @Override
                         public void onClick(DialogInterface dialog, int which) {