Merge "When adding a new call, use same phone account for call." into lmp-mr1-dev
diff --git a/Android.mk b/Android.mk
index 395aacc..0917793 100644
--- a/Android.mk
+++ b/Android.mk
@@ -4,8 +4,6 @@
include $(CLEAR_VARS)
LOCAL_JAVA_LIBRARIES := telephony-common
-LOCAL_STATIC_JAVA_LIBRARIES := \
- guava \
LOCAL_SRC_FILES := $(call all-java-files-under, src)
diff --git a/res/values-ar/strings.xml b/res/values-ar/strings.xml
index 2362585..57873d2 100644
--- a/res/values-ar/strings.xml
+++ b/res/values-ar/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"رد سريع"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"إعادة تعيين التطبيق الافتراضي"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"تم إرسال الرسالة إلى <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"مسموح لمالك الجهاز بمكالمات الطوارئ فقط"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"لإجراء مكالمة، أدخل رقمًا صالحًا."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"لا يمكن إضافة مكالمة في الوقت الحالي."</string>
<string name="no_vm_number" msgid="4164780423805688336">"رقم البريد الصوتي مفقود"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"لم يتم تخزين رقم بريد صوتي على بطاقة SIM."</string>
diff --git a/res/values-en-rGB/strings.xml b/res/values-en-rGB/strings.xml
index 6a34377..0c1e455 100644
--- a/res/values-en-rGB/strings.xml
+++ b/res/values-en-rGB/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Quick response"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Reset default app"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Message sent to <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Only emergency calls are allowed by the device owner"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"To place a call, enter a valid number."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Call cannot be added at this time."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Missing voicemail number"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"No voicemail number is stored on the SIM card."</string>
diff --git a/res/values-en-rIN/strings.xml b/res/values-en-rIN/strings.xml
index 6a34377..0c1e455 100644
--- a/res/values-en-rIN/strings.xml
+++ b/res/values-en-rIN/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Quick response"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Reset default app"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Message sent to <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Only emergency calls are allowed by the device owner"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"To place a call, enter a valid number."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Call cannot be added at this time."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Missing voicemail number"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"No voicemail number is stored on the SIM card."</string>
diff --git a/res/values-hy-rAM/strings.xml b/res/values-hy-rAM/strings.xml
index c15e745..477bad1 100644
--- a/res/values-hy-rAM/strings.xml
+++ b/res/values-hy-rAM/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Արագ պատասխան"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Վերականգնել լռելյայն հավելվածը"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Հաղորդագրությունն ուղարկվել է <xliff:g id="PHONE_NUMBER">%s</xliff:g>-ին:"</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Սարքի սեփականատերը թույլատրում է միայն արտակարգ իրավիճակի զանգերը"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Զանգ կատարելու համար մուտքագրեք ճիշտ համար:"</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Հնարավոր չէ ևս մեկ զանգ ավելացնել այս պահին:"</string>
<string name="no_vm_number" msgid="4164780423805688336">"Բացակայում է ձայնային փոստի համարը"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"SIM քարտում ձայնային փոստի ոչ մի համար գրանցված չէ:"</string>
diff --git a/res/values-in/strings.xml b/res/values-in/strings.xml
index c022a73..87fb929 100644
--- a/res/values-in/strings.xml
+++ b/res/values-in/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Tanggapan cepat"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Setel ulang aplikasi default"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Pesan dikirim ke <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Hanya panggilan darurat yang diizinkan oleh pemilik perangkat"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Untuk melakukan panggilan telepon, masukkan nomor yang valid."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Panggilan tidak dapat ditambahkan untuk saat ini."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Nomor kotak pesan hilang"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"Tidak ada nomor kotak pesan tersimpan pada kartu SIM."</string>
diff --git a/res/values-iw/strings.xml b/res/values-iw/strings.xml
index c42e4f0..0c568f8 100644
--- a/res/values-iw/strings.xml
+++ b/res/values-iw/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"תגובה מהירה"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"אפס את האפליקציה המוגדר כברירת מחדל"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"הודעה נשלחה אל <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"בעלי המכשיר מתיר לבצע שיחות חירום בלבד"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"כדי להתקשר, הזן מספר טלפון חוקי."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"לא ניתן כעת להוסיף את השיחה."</string>
<string name="no_vm_number" msgid="4164780423805688336">"חסר מספר של דואר קולי"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"בכרטיס ה-SIM לא מאוחסן מספר של דואר קולי."</string>
diff --git a/res/values-kk-rKZ/strings.xml b/res/values-kk-rKZ/strings.xml
index b904279..dc00f4e 100644
--- a/res/values-kk-rKZ/strings.xml
+++ b/res/values-kk-rKZ/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Жылдам жауап"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Бастапқы қолдб-ға қайта реттеу"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Хабар <xliff:g id="PHONE_NUMBER">%s</xliff:g> нөміріне жіберілді."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Құрылғы иесі тек жедел қоңырауларға рұқсат еткен"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Қоңырау шалу үшін жарамды нөмірді енгізіңіз."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Қоңырауды қазіргі уақытта қосу мүмкін емес."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Дауыс хабарының нөмірі жоқ"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"SIM картасында ешқандай дауыс хабарының нөмірі сақталмаған."</string>
diff --git a/res/values-km-rKH/strings.xml b/res/values-km-rKH/strings.xml
index e9da6d0..551e684 100644
--- a/res/values-km-rKH/strings.xml
+++ b/res/values-km-rKH/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"ឆ្លើយតបរហ័ស"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"កំណត់កម្មវិធីលំនាំដើមឡើងវិញ"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"បានផ្ញើសារទៅ <xliff:g id="PHONE_NUMBER">%s</xliff:g> ។"</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"ការហៅពេលមានអាសន្នដែលត្រូវបានអនុញ្ញាតដោយម្ចាស់ឧបករណ៍តែប៉ុណ្ណោះ។"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"ដើម្បីធ្វើការហៅ បញ្ចូលលេខដែលមានសុពលភាព។"</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"មិនអាចបន្ថែមនៅពេលនេះបានទេ។"</string>
<string name="no_vm_number" msgid="4164780423805688336">"បាត់ចំនួនសារជាសំឡេង"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"គ្មានចំនួនសារជាសំឡេងត្រូវបានរក្សាទុកនៅលើស៊ីមកាតទេ។"</string>
diff --git a/res/values-ky-rKG/strings.xml b/res/values-ky-rKG/strings.xml
index e275fcf..53abf03 100644
--- a/res/values-ky-rKG/strings.xml
+++ b/res/values-ky-rKG/strings.xml
@@ -45,10 +45,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Тез жооп"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Абалкы колдонмону өзгөртүү"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"<xliff:g id="PHONE_NUMBER">%s</xliff:g> номуруна билдирүү жөнөтүлдү."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Түзмөк ээси шашылыш чалууларга гана уруксат берген"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Чалуу үчүн, жарактуу номер киргизиңиз."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Бул жолу чалууну кошуу мүмкүн эмес."</string>
<!-- no translation found for no_vm_number (4164780423805688336) -->
<skip />
diff --git a/res/values-lo-rLA/strings.xml b/res/values-lo-rLA/strings.xml
index 7147030..5a8e88a 100644
--- a/res/values-lo-rLA/strings.xml
+++ b/res/values-lo-rLA/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"ຕອບກັບດ່ວນ"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"ຄືນຄ່າແອັບຯເລີ່ມຕົ້ນ"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"ສົ່ງຂໍ້ຄວາມຫາ <xliff:g id="PHONE_NUMBER">%s</xliff:g> ແລ້ວ."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"ພຽງແຕ່ການໂທສຸກເສີນທີ່ໄດ້ຮັບອະນຸຍາດຈາກເຈົ້າຂອງອຸປະກອນເທົ່ານັ້ນ"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"ເພື່ອທີ່ຈະໂທ, ປ້ອນເບີໂທທີ່ໃຊ້ໄດ້ເຂົ້າໄປ."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"ບໍ່ສາມາດເພີ່ມການໂທໄດ້ໃນເວລານີ້."</string>
<string name="no_vm_number" msgid="4164780423805688336">"ບໍ່ມີເບີຂໍ້ຄວາມສຽງ"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"ບໍ່ມີເບີຂໍ້ຄວາມສຽງຖືກບັນທຶກໃນ SIM card."</string>
diff --git a/res/values-mk-rMK/strings.xml b/res/values-mk-rMK/strings.xml
index a81e80a..d340235 100644
--- a/res/values-mk-rMK/strings.xml
+++ b/res/values-mk-rMK/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Брз одговор"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Ресетирај стандардна апликација"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Порака е испратена на <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Дозволени се само итни повици од страна на сопственикот на уредот"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"За да повикате, внесете важечки број."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Повикот не може да се додаде во моментов."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Недостасува број на говорна пошта"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"Нема мемориран број на говорна пошта на СИМ картичката."</string>
diff --git a/res/values-ne-rNP/strings.xml b/res/values-ne-rNP/strings.xml
index 6afabd4..0f74870 100644
--- a/res/values-ne-rNP/strings.xml
+++ b/res/values-ne-rNP/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"द्रुत प्रतिक्रिया"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"पूर्वनिर्धारित अनुप्रयोग पुनःसेट गर्नुहोस्"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"<xliff:g id="PHONE_NUMBER">%s</xliff:g> लाई सन्देश पठाइयो।"</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"केवल आपतकालीन कलहरू मात्र यन्त्र मालिकद्वारा अनुमति दिइएको छ"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"एक कल गर्नको लागि, एक वैध नम्बर प्रविष्ट गर्नुहोस्।"</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"यस समयमा कल थप गर्न सकिँदैन।"</string>
<string name="no_vm_number" msgid="4164780423805688336">"भ्वाइसमेल नम्बर हराइरहेको छ"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"SIM कार्डमा कुनै पनि भ्वाइसमेल नम्बर भण्डारण भएको छैन।"</string>
diff --git a/res/values-nl/strings.xml b/res/values-nl/strings.xml
index 684457b..7039ad1 100644
--- a/res/values-nl/strings.xml
+++ b/res/values-nl/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Snelle reactie"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Standaardapp opnieuw instellen"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Bericht verzonden naar <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Alleen noodoproepen zijn toegestaan door de apparaateigenaar"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Als u wilt bellen, moet u een geldig nummer invoeren."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Oproep kan momenteel niet worden toegevoegd."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Voicemailnummer ontbreekt"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"Er is geen voicemailnummer op de SIM-kaart opgeslagen."</string>
diff --git a/res/values-si-rLK/strings.xml b/res/values-si-rLK/strings.xml
index 2769b7a..212fbd4 100644
--- a/res/values-si-rLK/strings.xml
+++ b/res/values-si-rLK/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"ක්ෂණික ප්රතිචාරය"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"සුපුරුදු යෙදුම යළි සකසන්න"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"<xliff:g id="PHONE_NUMBER">%s</xliff:g> හට පණිවිඩය යවන්න."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"උපාංගයේ හිමිකරු විසින් හදිස්සි ඇමතුම් වලට පමණක් අවසර දෙයි"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"ඇමතුමක් ලබාගැනීමට, වලංගු අංකයක් ලබාගන්න."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"මේ වේලාවේ ඇමතුම එකතු කළ නොහැක."</string>
<string name="no_vm_number" msgid="4164780423805688336">"හඬ තැපැල් අංකය නැත"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"SIM කාඩ් පතෙහි හඬ තැපැල් අංකයක් ආචිත වී නැත."</string>
diff --git a/res/values-th/strings.xml b/res/values-th/strings.xml
index 3535d1f..a86e37c 100644
--- a/res/values-th/strings.xml
+++ b/res/values-th/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"คำตอบด่วน"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"รีเซ็ตแอปพลิเคชันเริ่มต้น"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"ส่งข้อความไปยัง <xliff:g id="PHONE_NUMBER">%s</xliff:g> แล้ว"</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"เจ้าของอุปกรณ์อนุญาตเฉพาะหมายเลขฉุกเฉิน"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"หากต้องการโทรออก โปรดป้อนหมายเลขที่ถูกต้อง"</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"ไม่สามารถเพิ่มสายได้ในขณะนี้"</string>
<string name="no_vm_number" msgid="4164780423805688336">"ไม่มีหมายเลขข้อความเสียง"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"ไม่มีหมายเลขข้อความเสียงจัดเก็บอยู่ในซิมการ์ด"</string>
diff --git a/res/values-uk/strings.xml b/res/values-uk/strings.xml
index 4803e5a..74c4448 100644
--- a/res/values-uk/strings.xml
+++ b/res/values-uk/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Швидка відповідь"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Скинути програму за умовчанням"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Повідомлення надіслано на номер <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Власник пристрою дозволив лише екстрені виклики"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Щоб зателефонувати, введіть дійсний номер."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Зараз не можна почати дзвінок."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Відстун. номер голос. пошти"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"На SIM-карті немає збереж. номерів голос. пошти."</string>
diff --git a/res/values-uz-rUZ/strings.xml b/res/values-uz-rUZ/strings.xml
index d80c876..6cff381 100644
--- a/res/values-uz-rUZ/strings.xml
+++ b/res/values-uz-rUZ/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Tezkor javob"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Standart ilovani tiklash"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Xabar <xliff:g id="PHONE_NUMBER">%s</xliff:g>ga jo‘natildi."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Qurilma egasi faqat favqulodda qo‘ng‘iroqlarga ruxsat bergan"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Qo‘ng‘iroq qilish uchun raqamni to‘g‘ri kiriting."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Hozirgi vaqtda qo‘ng‘iroq qo‘shib bo‘lmaydi."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Javobsiz ovozli xabar raqami"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"SIM kartada birorta ham ovozli xabar saqlanmagan."</string>
diff --git a/res/values-vi/strings.xml b/res/values-vi/strings.xml
index 86a7387..a690c4c 100644
--- a/res/values-vi/strings.xml
+++ b/res/values-vi/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Trả lời nhanh"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Đặt lại ứng dụng mặc định"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Đã gửi tin nhắn tới <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Chỉ chủ sở hữu thiết bị mới được phép thực hiện cuộc gọi khẩn cấp"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Để thực hiện cuộc gọi, hãy nhập một số hợp lệ."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Không thể thêm cuộc gọi tại thời điểm này."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Thiếu số thư thoại"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"Không có số thư thoại nào được lưu trữ trên thẻ SIM."</string>
diff --git a/res/values-zu/strings.xml b/res/values-zu/strings.xml
index cf5e517..3b3969d 100644
--- a/res/values-zu/strings.xml
+++ b/res/values-zu/strings.xml
@@ -36,10 +36,8 @@
<string name="respond_via_sms_edittext_dialog_title" msgid="20379890418289778">"Izimpendulo ezisheshayo"</string>
<string name="respond_via_sms_menu_reset_default_activity" msgid="1461742052902053466">"Setha kabusha uhlelo lokusebenza lokuzenzakalelayo"</string>
<string name="respond_via_sms_confirmation_format" msgid="7229149977515784269">"Umlayezo othunyelwe ku <xliff:g id="PHONE_NUMBER">%s</xliff:g>."</string>
- <!-- no translation found for outgoing_call_not_allowed (1435394568102165287) -->
- <skip />
- <!-- no translation found for outgoing_call_error_no_phone_number_supplied (1940125199802007505) -->
- <skip />
+ <string name="outgoing_call_not_allowed" msgid="1435394568102165287">"Amakholi wesimo esiphuthumayo kuphela avunyelwe ngumnikazi wedivayisi"</string>
+ <string name="outgoing_call_error_no_phone_number_supplied" msgid="1940125199802007505">"Ukuze wenze ikholi, faka inombolo evumelekile."</string>
<string name="duplicate_video_call_not_allowed" msgid="3749211605014548386">"Ikholi ayikwazi ukungezwa ngalesi sikhathi."</string>
<string name="no_vm_number" msgid="4164780423805688336">"Inombolo engekho yomyalezo wezwi"</string>
<string name="no_vm_number_msg" msgid="1300729501030053828">"Ayikho inombolo yomlayezo wezwi egcinwe ekhadini le-SIM."</string>
diff --git a/src/com/android/server/telecom/AsyncRingtonePlayer.java b/src/com/android/server/telecom/AsyncRingtonePlayer.java
index 4434424..3030fea 100644
--- a/src/com/android/server/telecom/AsyncRingtonePlayer.java
+++ b/src/com/android/server/telecom/AsyncRingtonePlayer.java
@@ -196,7 +196,9 @@
}
Ringtone ringtone = RingtoneManager.getRingtone(mContext, ringtoneUri);
- ringtone.setStreamType(AudioManager.STREAM_RING);
+ if (ringtone != null) {
+ ringtone.setStreamType(AudioManager.STREAM_RING);
+ }
return ringtone;
}
}
diff --git a/src/com/android/server/telecom/Call.java b/src/com/android/server/telecom/Call.java
index 67ff03a..47b4aa6f 100644
--- a/src/com/android/server/telecom/Call.java
+++ b/src/com/android/server/telecom/Call.java
@@ -189,6 +189,12 @@
*/
private long mCreationTimeMillis = System.currentTimeMillis();
+ /** The time this call was made active. */
+ private long mConnectTimeMillis = 0;
+
+ /** The time this call was disconnected. */
+ private long mDisconnectTimeMillis = 0;
+
/** The gateway information associated with this call. This stores the original call handle
* that the user is attempting to connect to via the gateway, the actual handle to dial in
* order to connect the call via the gateway, as well as the package name of the gateway
@@ -203,8 +209,6 @@
private final List<Call> mConferenceableCalls = new ArrayList<>();
- private long mConnectTimeMillis = 0;
-
/** The state of the call. */
private int mState;
@@ -386,7 +390,18 @@
mState = newState;
maybeLoadCannedSmsResponses();
- if (mState == CallState.DISCONNECTED) {
+ if (mState == CallState.ACTIVE || mState == CallState.ON_HOLD) {
+ if (mConnectTimeMillis == 0) {
+ // We check to see if mConnectTime is already set to prevent the
+ // call from resetting active time when it goes in and out of
+ // ACTIVE/ON_HOLD
+ mConnectTimeMillis = System.currentTimeMillis();
+ }
+
+ // We're clearly not disconnected, so reset the disconnected time.
+ mDisconnectTimeMillis = 0;
+ } else if (mState == CallState.DISCONNECTED) {
+ mDisconnectTimeMillis = System.currentTimeMillis();
setLocallyDisconnecting(false);
fixParentAfterDisconnect();
if ((oldState == CallState.DIALING || oldState == CallState.CONNECTING)
@@ -559,7 +574,21 @@
* mCreationTimeMillis.
*/
long getAgeMillis() {
- return System.currentTimeMillis() - mCreationTimeMillis;
+ if (mState == CallState.DISCONNECTED &&
+ (mDisconnectCause.getCode() == DisconnectCause.REJECTED ||
+ mDisconnectCause.getCode() == DisconnectCause.MISSED)) {
+ // Rejected and missed calls have no age. They're immortal!!
+ return 0;
+ } else if (mConnectTimeMillis == 0) {
+ // Age is measured in the amount of time the call was active. A zero connect time
+ // indicates that we never went active, so return 0 for the age.
+ return 0;
+ } else if (mDisconnectTimeMillis == 0) {
+ // We connected, but have not yet disconnected
+ return System.currentTimeMillis() - mConnectTimeMillis;
+ }
+
+ return mDisconnectTimeMillis - mConnectTimeMillis;
}
/**
@@ -578,10 +607,6 @@
return mConnectTimeMillis;
}
- void setConnectTimeMillis(long connectTimeMillis) {
- mConnectTimeMillis = connectTimeMillis;
- }
-
int getCallCapabilities() {
return mCallCapabilities;
}
diff --git a/src/com/android/server/telecom/CallIdMapper.java b/src/com/android/server/telecom/CallIdMapper.java
index 40a50a5..729db0a 100644
--- a/src/com/android/server/telecom/CallIdMapper.java
+++ b/src/com/android/server/telecom/CallIdMapper.java
@@ -16,11 +16,65 @@
package com.android.server.telecom;
-import com.google.common.collect.HashBiMap;
+import android.util.ArrayMap;
+
+import java.util.Map;
/** Utility to map {@link Call} objects to unique IDs. IDs are generated when a call is added. */
class CallIdMapper {
- private final HashBiMap<String, Call> mCalls = HashBiMap.create();
+ /**
+ * A very basic bidirectional map.
+ */
+ static class BiMap<K, V> {
+ private Map<K, V> mPrimaryMap = new ArrayMap<>();
+ private Map<V, K> mSecondaryMap = new ArrayMap<>();
+
+ public boolean put(K key, V value) {
+ if (key == null || value == null || mPrimaryMap.containsKey(key) ||
+ mSecondaryMap.containsKey(value)) {
+ return false;
+ }
+
+ mPrimaryMap.put(key, value);
+ mSecondaryMap.put(value, key);
+ return true;
+ }
+
+ public boolean remove(K key) {
+ if (key == null) {
+ return false;
+ }
+ if (mPrimaryMap.containsKey(key)) {
+ V value = getValue(key);
+ mPrimaryMap.remove(key);
+ mSecondaryMap.remove(value);
+ return true;
+ }
+ return false;
+ }
+
+ public boolean removeValue(V value) {
+ if (value == null) {
+ return false;
+ }
+ return remove(getKey(value));
+ }
+
+ public V getValue(K key) {
+ return mPrimaryMap.get(key);
+ }
+
+ public K getKey(V value) {
+ return mSecondaryMap.get(value);
+ }
+
+ public void clear() {
+ mPrimaryMap.clear();
+ mSecondaryMap.clear();
+ }
+ }
+
+ private final BiMap<String, Call> mCalls = new BiMap<>();
private final String mCallIdPrefix;
private static int sIdCount;
@@ -55,7 +109,7 @@
return;
}
ThreadUtil.checkOnMainThread();
- mCalls.inverse().remove(call);
+ mCalls.removeValue(call);
}
void removeCall(String callId) {
@@ -68,7 +122,7 @@
return null;
}
ThreadUtil.checkOnMainThread();
- return mCalls.inverse().get(call);
+ return mCalls.getKey(call);
}
Call getCall(Object objId) {
@@ -82,7 +136,7 @@
return null;
}
- return mCalls.get(callId);
+ return mCalls.getValue(callId);
}
void clear() {
diff --git a/src/com/android/server/telecom/CallLogManager.java b/src/com/android/server/telecom/CallLogManager.java
index 8764a04..781f2b1 100755
--- a/src/com/android/server/telecom/CallLogManager.java
+++ b/src/com/android/server/telecom/CallLogManager.java
@@ -140,13 +140,12 @@
Log.d(TAG, "logNumber set to: %s", Log.pii(logNumber));
- final int presentation = getPresentation(call);
final PhoneAccountHandle accountHandle = call.getTargetPhoneAccount();
// TODO(vt): Once data usage is available, wire it up here.
int callFeatures = getCallFeatures(call.getVideoStateHistory());
- logCall(call.getCallerInfo(), logNumber, presentation, callLogType, callFeatures,
- accountHandle, creationTime, age, null);
+ logCall(call.getCallerInfo(), logNumber, call.getHandlePresentation(),
+ callLogType, callFeatures, accountHandle, creationTime, age, null);
}
/**
@@ -232,21 +231,6 @@
}
/**
- * Gets the presentation from the {@link Call}.
- *
- * TODO: There needs to be a way to pass information from
- * Connection.getNumberPresentation() into a {@link Call} object. Until then, always return
- * PhoneConstants.PRESENTATION_ALLOWED. On top of that, we might need to introduce
- * getNumberPresentation to the ContactInfo object as well.
- *
- * @param call The call object to retrieve caller details from.
- * @return The number presentation constant to insert into the call logs.
- */
- private int getPresentation(Call call) {
- return PhoneConstants.PRESENTATION_ALLOWED;
- }
-
- /**
* Adds the call defined by the parameters in the provided AddCallArgs to the CallLogProvider
* using an AsyncTask to avoid blocking the main thread.
*
diff --git a/src/com/android/server/telecom/CallsManager.java b/src/com/android/server/telecom/CallsManager.java
index 9762797..7bbe031 100644
--- a/src/com/android/server/telecom/CallsManager.java
+++ b/src/com/android/server/telecom/CallsManager.java
@@ -40,9 +40,7 @@
import com.android.internal.util.IndentingPrintWriter;
-import com.google.common.collect.ImmutableCollection;
-import com.google.common.collect.ImmutableList;
-
+import java.util.Collection;
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
@@ -314,8 +312,8 @@
return true;
}
- ImmutableCollection<Call> getCalls() {
- return ImmutableList.copyOf(mCalls);
+ Collection<Call> getCalls() {
+ return Collections.unmodifiableCollection(mCalls);
}
Call getForegroundCall() {
@@ -408,7 +406,6 @@
// to the existing connection instead of trying to create a new one.
true /* isIncoming */,
false /* isConference */);
- call.setConnectTimeMillis(System.currentTimeMillis());
call.setIsUnknown(true);
call.setExtras(extras);
call.addListener(this);
@@ -806,9 +803,6 @@
}
void markCallAsActive(Call call) {
- if (call.getConnectTimeMillis() == 0) {
- call.setConnectTimeMillis(System.currentTimeMillis());
- }
setCallState(call, CallState.ACTIVE);
if (call.getStartWithSpeakerphoneOn()) {
@@ -1000,9 +994,6 @@
true /* isConference */);
setCallState(call, Call.getStateFromConnectionState(parcelableConference.getState()));
- if (call.getState() == CallState.ACTIVE) {
- call.setConnectTimeMillis(System.currentTimeMillis());
- }
call.setCallCapabilities(parcelableConference.getCapabilities());
// TODO: Move this to be a part of addCall()
@@ -1346,7 +1337,6 @@
false /* isConference */);
setCallState(call, Call.getStateFromConnectionState(connection.getState()));
- call.setConnectTimeMillis(System.currentTimeMillis());
call.setCallCapabilities(connection.getCapabilities());
call.setCallerDisplayName(connection.getCallerDisplayName(),
connection.getCallerDisplayNamePresentation());
diff --git a/src/com/android/server/telecom/DtmfLocalTonePlayer.java b/src/com/android/server/telecom/DtmfLocalTonePlayer.java
index 6b4b74d..562f8d3 100644
--- a/src/com/android/server/telecom/DtmfLocalTonePlayer.java
+++ b/src/com/android/server/telecom/DtmfLocalTonePlayer.java
@@ -22,9 +22,6 @@
import android.provider.Settings;
// TODO: Needed for move to system service: import com.android.internal.R;
-import com.google.common.collect.ImmutableMap;
-
-import java.util.Map;
/**
* Plays DTMF tones locally for the caller to hear. In order to reduce (1) the amount of times we
@@ -33,22 +30,6 @@
* changes.
*/
class DtmfLocalTonePlayer extends CallsManagerListenerBase {
- private static final Map<Character, Integer> TONE_MAP =
- ImmutableMap.<Character, Integer>builder()
- .put('1', ToneGenerator.TONE_DTMF_1)
- .put('2', ToneGenerator.TONE_DTMF_2)
- .put('3', ToneGenerator.TONE_DTMF_3)
- .put('4', ToneGenerator.TONE_DTMF_4)
- .put('5', ToneGenerator.TONE_DTMF_5)
- .put('6', ToneGenerator.TONE_DTMF_6)
- .put('7', ToneGenerator.TONE_DTMF_7)
- .put('8', ToneGenerator.TONE_DTMF_8)
- .put('9', ToneGenerator.TONE_DTMF_9)
- .put('0', ToneGenerator.TONE_DTMF_0)
- .put('#', ToneGenerator.TONE_DTMF_P)
- .put('*', ToneGenerator.TONE_DTMF_S)
- .build();
-
/** Generator used to actually play the tone. */
private ToneGenerator mToneGenerator;
@@ -85,8 +66,9 @@
Log.d(this, "playTone: mToneGenerator == null, %c.", c);
} else {
Log.d(this, "starting local tone: %c.", c);
- if (TONE_MAP.containsKey(c)) {
- mToneGenerator.startTone(TONE_MAP.get(c), -1 /* toneDuration */);
+ int tone = getMappedTone(c);
+ if (tone != ToneGenerator.TONE_UNKNOWN) {
+ mToneGenerator.startTone(tone, -1 /* toneDuration */);
}
}
}
@@ -160,4 +142,15 @@
}
}
}
+
+ private static final int getMappedTone(char digit) {
+ if (digit >= '0' && digit <= '9') {
+ return ToneGenerator.TONE_DTMF_0 + digit - '0';
+ } else if (digit == '#') {
+ return ToneGenerator.TONE_DTMF_P;
+ } else if (digit == '*') {
+ return ToneGenerator.TONE_DTMF_S;
+ }
+ return ToneGenerator.TONE_UNKNOWN;
+ }
}
diff --git a/src/com/android/server/telecom/InCallAdapter.java b/src/com/android/server/telecom/InCallAdapter.java
index d4af791..e39b5a5 100644
--- a/src/com/android/server/telecom/InCallAdapter.java
+++ b/src/com/android/server/telecom/InCallAdapter.java
@@ -102,8 +102,6 @@
break;
case MSG_POST_DIAL_CONTINUE:
call = mCallIdMapper.getCall(msg.obj);
- mCallsManager.postDialContinue(call, msg.arg1 == 1);
- call = mCallIdMapper.getCall(msg.obj);
if (call != null) {
mCallsManager.postDialContinue(call, msg.arg1 == 1);
} else {
diff --git a/src/com/android/server/telecom/InCallController.java b/src/com/android/server/telecom/InCallController.java
index 9498d4c..d3cc232 100644
--- a/src/com/android/server/telecom/InCallController.java
+++ b/src/com/android/server/telecom/InCallController.java
@@ -40,13 +40,13 @@
import android.util.ArrayMap;
+
// TODO: Needed for move to system service: import com.android.internal.R;
import com.android.internal.telecom.IInCallService;
import com.android.internal.util.IndentingPrintWriter;
-import com.google.common.collect.ImmutableCollection;
-
import java.util.ArrayList;
+import java.util.Collection;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
@@ -355,7 +355,7 @@
}
// Upon successful connection, send the state of the world to the service.
- ImmutableCollection<Call> calls = CallsManager.getInstance().getCalls();
+ Collection<Call> calls = CallsManager.getInstance().getCalls();
if (!calls.isEmpty()) {
Log.i(this, "Adding %s calls to InCallService after onConnected: %s", calls.size(),
componentName);
@@ -443,7 +443,7 @@
*
* @param call The {@link Call} to parcel.
* @param includeVideoProvider When {@code true}, the {@link IVideoProvider} is included in the
- * parcelled call. When {@code false}, the {@link IVideoProvider} is not included.
+ * parceled call. When {@code false}, the {@link IVideoProvider} is not included.
* @return The {@link ParcelableCall} containing all call information from the {@link Call}.
*/
private ParcelableCall toParcelableCall(Call call, boolean includeVideoProvider) {
@@ -452,7 +452,10 @@
int state = call.getState();
int capabilities = call.getCallCapabilities();
- if (call.isRespondViaSmsCapable()) {
+ boolean isDefaultSmsAccount =
+ CallsManager.getInstance().getPhoneAccountRegistrar().isUserSelectedSmsPhoneAccount(
+ call.getTargetPhoneAccount());
+ if (call.isRespondViaSmsCapable() && isDefaultSmsAccount) {
capabilities |= PhoneCapabilities.RESPOND_VIA_TEXT;
}
diff --git a/src/com/android/server/telecom/NewOutgoingCallIntentBroadcaster.java b/src/com/android/server/telecom/NewOutgoingCallIntentBroadcaster.java
index b0495ac..c52f2bb 100644
--- a/src/com/android/server/telecom/NewOutgoingCallIntentBroadcaster.java
+++ b/src/com/android/server/telecom/NewOutgoingCallIntentBroadcaster.java
@@ -173,7 +173,8 @@
boolean isVoicemailNumber = PhoneAccount.SCHEME_VOICEMAIL.equals(handle.getScheme());
if (isVoicemailNumber) {
- if (Intent.ACTION_CALL.equals(action)) {
+ if (Intent.ACTION_CALL.equals(action)
+ || Intent.ACTION_CALL_PRIVILEGED.equals(action)) {
// Voicemail calls will be handled directly by the telephony connection manager
Log.i(this, "Placing call immediately instead of waiting for "
+ " OutgoingCallBroadcastReceiver: %s", intent);
diff --git a/src/com/android/server/telecom/PhoneAccountRegistrar.java b/src/com/android/server/telecom/PhoneAccountRegistrar.java
index 1d7993d..ac02a88 100644
--- a/src/com/android/server/telecom/PhoneAccountRegistrar.java
+++ b/src/com/android/server/telecom/PhoneAccountRegistrar.java
@@ -92,6 +92,7 @@
private final List<Listener> mListeners = new CopyOnWriteArrayList<>();
private final AtomicFile mAtomicFile;
private final Context mContext;
+ private final SubscriptionManager mSubscriptionManager;
private State mState;
@VisibleForTesting
@@ -113,6 +114,7 @@
mState = new State();
mContext = context;
+ mSubscriptionManager = SubscriptionManager.from(mContext);
read();
}
@@ -130,7 +132,7 @@
!TextUtils.isDigitsOnly(accountHandle.getId())) {
// Since no decimals or negative numbers can be valid subscription ids, only a string of
// numbers can be subscription id
- return SubscriptionManager.INVALID_SUB_ID;
+ return SubscriptionManager.INVALID_SUBSCRIPTION_ID;
}
return Integer.parseInt(accountHandle.getId());
}
@@ -212,7 +214,7 @@
// If the account selected is a SIM account, propagate down to the subscription
// record.
int subId = getSubscriptionIdForPhoneAccount(accountHandle);
- SubscriptionManager.setDefaultVoiceSubId(subId);
+ mSubscriptionManager.setDefaultVoiceSubId(subId);
}
mState.defaultOutgoing = accountHandle;
@@ -222,6 +224,11 @@
fireDefaultOutgoingChanged();
}
+ boolean isUserSelectedSmsPhoneAccount(PhoneAccountHandle accountHandle) {
+ return getSubscriptionIdForPhoneAccount(accountHandle) ==
+ SubscriptionManager.getDefaultSmsSubId();
+ }
+
public void setSimCallManager(PhoneAccountHandle callManager) {
if (callManager != null) {
PhoneAccount callManagerAccount = getPhoneAccount(callManager);
diff --git a/src/com/android/server/telecom/RespondViaSmsManager.java b/src/com/android/server/telecom/RespondViaSmsManager.java
index ae7e713..8164df0 100644
--- a/src/com/android/server/telecom/RespondViaSmsManager.java
+++ b/src/com/android/server/telecom/RespondViaSmsManager.java
@@ -191,7 +191,7 @@
final Uri uri = Uri.fromParts(Constants.SCHEME_SMSTO, phoneNumber, null);
final Intent intent = new Intent(TelephonyManager.ACTION_RESPOND_VIA_MESSAGE, uri);
intent.putExtra(Intent.EXTRA_TEXT, textMessage);
- if (subId != SubscriptionManager.INVALID_SUB_ID) {
+ if (subId != SubscriptionManager.INVALID_SUBSCRIPTION_ID) {
intent.putExtra(PhoneConstants.SUBSCRIPTION_KEY, subId);
}
diff --git a/src/com/android/server/telecom/Ringer.java b/src/com/android/server/telecom/Ringer.java
index 5945306..6b46a71 100644
--- a/src/com/android/server/telecom/Ringer.java
+++ b/src/com/android/server/telecom/Ringer.java
@@ -252,7 +252,7 @@
private boolean shouldVibrate(Context context) {
AudioManager audioManager = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
- int ringerMode = audioManager.getRingerMode();
+ int ringerMode = audioManager.getRingerModeInternal();
if (getVibrateWhenRinging(context)) {
return ringerMode != AudioManager.RINGER_MODE_SILENT;
} else {
diff --git a/src/com/android/server/telecom/ServiceBinder.java b/src/com/android/server/telecom/ServiceBinder.java
index fb747f2..4b30990 100644
--- a/src/com/android/server/telecom/ServiceBinder.java
+++ b/src/com/android/server/telecom/ServiceBinder.java
@@ -22,11 +22,10 @@
import android.content.ServiceConnection;
import android.os.IBinder;
import android.os.IInterface;
+import android.text.TextUtils;
+import android.util.ArraySet;
import com.android.internal.util.Preconditions;
-import com.google.common.base.Strings;
-
-import com.google.common.collect.Sets;
import java.util.Collections;
import java.util.Set;
@@ -136,7 +135,7 @@
private final ComponentName mComponentName;
/** The set of callbacks waiting for notification of the binding's success or failure. */
- private final Set<BindCallback> mCallbacks = Sets.newHashSet();
+ private final Set<BindCallback> mCallbacks = new ArraySet<>();
/** Used to bind and unbind from the service. */
private ServiceConnection mServiceConnection;
@@ -169,7 +168,7 @@
* @param context The context.
*/
protected ServiceBinder(String serviceAction, ComponentName componentName, Context context) {
- Preconditions.checkState(!Strings.isNullOrEmpty(serviceAction));
+ Preconditions.checkState(!TextUtils.isEmpty(serviceAction));
Preconditions.checkNotNull(componentName);
mContext = context;