Merge "Revert "Prevent video calls that down graded to audio calls from merging to""
diff --git a/Android.bp b/Android.bp
index 76e910f..a06d5ef 100644
--- a/Android.bp
+++ b/Android.bp
@@ -22,7 +22,6 @@
"telephony-common",
"voip-common",
"ims-common",
- "org.apache.http.legacy",
"libprotobuf-java-lite",
"unsupportedappusage",
],
@@ -32,10 +31,10 @@
"androidx.preference_preference",
"androidx.recyclerview_recyclerview",
"androidx.legacy_legacy-preference-v14",
- "guava",
- "volley",
"android-support-annotations",
"com.android.phone.common-lib",
+ "guava",
+ "PlatformProperties",
],
srcs: [
@@ -79,4 +78,4 @@
proto: {
type: "lite",
},
-}
\ No newline at end of file
+}
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 34c67a4..98d1919 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -34,7 +34,6 @@
<protected-broadcast android:name="android.intent.action.ANY_DATA_STATE" />
<protected-broadcast android:name="android.intent.action.DATA_STALL_DETECTED" />
<protected-broadcast android:name="android.intent.action.SIM_STATE_CHANGED" />
- <protected-broadcast android:name="android.telephony.action.NETWORK_SET_TIME" />
<protected-broadcast android:name="com.android.internal.intent.action.ACTION_SHOW_NOTICE_ECM_BLOCK_OTHERS" />
<protected-broadcast android:name="android.intent.action.ACTION_MDN_STATE_CHANGED" />
<protected-broadcast android:name="android.provider.Telephony.SPN_STRINGS_UPDATED" />
@@ -76,7 +75,7 @@
<protected-broadcast android:name= "com.android.imsconnection.DISCONNECTED" />
<protected-broadcast android:name= "com.android.intent.action.IMS_FEATURE_CHANGED" />
<protected-broadcast android:name= "com.android.intent.action.IMS_CONFIG_CHANGED" />
- <protected-broadcast android:name= "com.android.ims.REGISTRATION_ERROR" />
+ <protected-broadcast android:name= "android.telephony.ims.action.WFC_IMS_REGISTRATION_ERROR" />
<protected-broadcast android:name= "com.android.phone.vvm.omtp.sms.REQUEST_SENT" />
<protected-broadcast android:name= "com.android.phone.vvm.ACTION_VISUAL_VOICEMAIL_SERVICE_EVENT" />
<protected-broadcast android:name= "com.android.internal.telephony.CARRIER_VVM_PACKAGE_INSTALLED" />
@@ -508,7 +507,7 @@
<receiver android:name="com.android.services.telephony.sip.SipIncomingCallReceiver">
<intent-filter>
- <action android:name="com.android.phone.SIP_INCOMING_CALL" />
+ <action android:name="android.net.sip.action.SIP_INCOMING_CALL" />
</intent-filter>
</receiver>
@@ -539,6 +538,12 @@
android:uiOptions="splitActionBarWhenNarrow">
</activity>
+ <service android:name="com.android.services.telephony.sip.components.TelephonySipService">
+ <intent-filter>
+ <action android:name="android.net.sip.action.START_SIP" />
+ </intent-filter>
+ </service>
+
<!-- End SIP -->
<activity android:name="MMIDialogActivity"
@@ -631,5 +636,33 @@
<action android:name="android.telephony.data.DataService" />
</intent-filter>
</service>
+
+ <provider
+ android:name="ServiceStateProvider"
+ android:authorities="service-state"
+ android:exported="true"
+ android:multiprocess="false"
+ android:singleUser="true"
+ android:writePermission="android.permission.MODIFY_PHONE_STATE"/>
+
+ <activity
+ android:name=".settings.RadioInfo"
+ android:label="@string/phone_info_label"
+ android:theme="@style/Theme.AppCompat.DayNight">
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN" />
+ <category android:name="android.intent.category.DEVELOPMENT_PREFERENCE" />
+ </intent-filter>
+ </activity>
+
+ <activity android:name=".settings.BandMode"
+ android:label="@string/band_mode_title"
+ android:theme="@style/Theme.AppCompat.DayNight">
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN" />
+ <category android:name="android.intent.category.DEFAULT" />
+ <category android:name="android.intent.category.VOICE_LAUNCH" />
+ </intent-filter>
+ </activity>
</application>
</manifest>
diff --git a/OWNERS b/OWNERS
index 5be6fe5..849347f 100644
--- a/OWNERS
+++ b/OWNERS
@@ -11,4 +11,5 @@
shuoq@google.com
paulye@google.com
nazaninb@google.com
-sarahchin@google.com
\ No newline at end of file
+sarahchin@google.com
+dbright@google.com
diff --git a/res/layout/emergency_dialer.xml b/res/layout/emergency_dialer.xml
index d14a679..ab32c62 100644
--- a/res/layout/emergency_dialer.xml
+++ b/res/layout/emergency_dialer.xml
@@ -58,8 +58,6 @@
android:accessibilityPaneTitle="@string/pane_title_emergency_dialpad"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:paddingLeft="36dp"
- android:paddingRight="36dp"
android:paddingBottom="@dimen/dialpad_bottom_padding"
android:visibility="visible">
<LinearLayout
@@ -73,6 +71,7 @@
android:id="@+id/emergency_action_group"
android:layout_height="64dp"
android:layout_width="match_parent"
+ android:layout_marginHorizontal="36dp"
android:layout_marginTop="16dp"
android:layout_marginBottom="24dp">
@@ -155,8 +154,14 @@
</FrameLayout>
</com.android.phone.EmergencyActionGroup>
-
+ <Space
+ android:id="@+id/emergency_info_dialpad_spacer"
+ android:layout_width="match_parent"
+ android:layout_height="0dp"
+ android:layout_weight="1"/>
<include layout="@layout/dialpad_view_unthemed"
+ android:layout_height="wrap_content"
+ android:layout_width="match_parent"
android:theme="?attr/dialpadTheme" />
</LinearLayout>
diff --git a/res/values-af/config.xml b/res/values-af/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-af/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-am/config.xml b/res/values-am/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-am/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ar/config.xml b/res/values-ar/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ar/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-as/config.xml b/res/values-as/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-as/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-az/config.xml b/res/values-az/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-az/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-b+sr+Latn/config.xml b/res/values-b+sr+Latn/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-b+sr+Latn/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-be/config.xml b/res/values-be/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-be/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-bg/config.xml b/res/values-bg/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-bg/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-bn/config.xml b/res/values-bn/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-bn/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-bs/config.xml b/res/values-bs/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-bs/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ca/config.xml b/res/values-ca/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ca/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-cs/config.xml b/res/values-cs/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-cs/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-da/config.xml b/res/values-da/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-da/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-de/config.xml b/res/values-de/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-de/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-el/config.xml b/res/values-el/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-el/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-en-rAU/config.xml b/res/values-en-rAU/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-en-rAU/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-en-rCA/config.xml b/res/values-en-rCA/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-en-rCA/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-en-rGB/config.xml b/res/values-en-rGB/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-en-rGB/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-en-rIN/config.xml b/res/values-en-rIN/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-en-rIN/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-en-rXC/config.xml b/res/values-en-rXC/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-en-rXC/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-es-rUS/config.xml b/res/values-es-rUS/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-es-rUS/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-es/config.xml b/res/values-es/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-es/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-et/config.xml b/res/values-et/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-et/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-eu/config.xml b/res/values-eu/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-eu/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-fa/config.xml b/res/values-fa/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-fa/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-fi/config.xml b/res/values-fi/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-fi/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-fr-rCA/config.xml b/res/values-fr-rCA/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-fr-rCA/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-fr/config.xml b/res/values-fr/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-fr/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-gl/config.xml b/res/values-gl/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-gl/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-gu/config.xml b/res/values-gu/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-gu/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-h500dp/dimens.xml b/res/values-h500dp/dimens.xml
index 2c7c797..d74f0a1 100644
--- a/res/values-h500dp/dimens.xml
+++ b/res/values-h500dp/dimens.xml
@@ -16,5 +16,5 @@
-->
<resources>
- <dimen name="dialpad_bottom_padding">36dp</dimen>
+ <dimen name="dialpad_bottom_padding">16dp</dimen>
</resources>
\ No newline at end of file
diff --git a/res/values-hi/config.xml b/res/values-hi/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-hi/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-hr/config.xml b/res/values-hr/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-hr/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-hu/config.xml b/res/values-hu/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-hu/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-hy/config.xml b/res/values-hy/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-hy/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-in/config.xml b/res/values-in/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-in/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-is/config.xml b/res/values-is/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-is/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-it/config.xml b/res/values-it/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-it/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-iw/config.xml b/res/values-iw/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-iw/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ja/config.xml b/res/values-ja/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ja/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ka/config.xml b/res/values-ka/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ka/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-kk/config.xml b/res/values-kk/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-kk/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-km/config.xml b/res/values-km/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-km/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-kn/config.xml b/res/values-kn/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-kn/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ko/config.xml b/res/values-ko/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ko/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ky/config.xml b/res/values-ky/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ky/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-lo/config.xml b/res/values-lo/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-lo/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-lt/config.xml b/res/values-lt/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-lt/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-lv/config.xml b/res/values-lv/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-lv/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-mk/config.xml b/res/values-mk/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-mk/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ml/config.xml b/res/values-ml/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ml/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-mn/config.xml b/res/values-mn/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-mn/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-mr/config.xml b/res/values-mr/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-mr/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ms/config.xml b/res/values-ms/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ms/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-my/config.xml b/res/values-my/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-my/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-nb/config.xml b/res/values-nb/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-nb/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ne/config.xml b/res/values-ne/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ne/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-nl/config.xml b/res/values-nl/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-nl/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-or/config.xml b/res/values-or/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-or/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-pa/config.xml b/res/values-pa/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-pa/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-pl/config.xml b/res/values-pl/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-pl/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-pt-rPT/config.xml b/res/values-pt-rPT/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-pt-rPT/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-pt/config.xml b/res/values-pt/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-pt/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ro/config.xml b/res/values-ro/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ro/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ru/config.xml b/res/values-ru/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ru/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-si/config.xml b/res/values-si/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-si/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-sk/config.xml b/res/values-sk/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-sk/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-sl/config.xml b/res/values-sl/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-sl/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-sq/config.xml b/res/values-sq/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-sq/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-sr/config.xml b/res/values-sr/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-sr/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-sv/config.xml b/res/values-sv/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-sv/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-sw/config.xml b/res/values-sw/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-sw/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ta/config.xml b/res/values-ta/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ta/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-te/config.xml b/res/values-te/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-te/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-th/config.xml b/res/values-th/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-th/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-tl/config.xml b/res/values-tl/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-tl/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-tr/config.xml b/res/values-tr/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-tr/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-uk/config.xml b/res/values-uk/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-uk/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-ur/config.xml b/res/values-ur/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-ur/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-uz/config.xml b/res/values-uz/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-uz/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-vi/config.xml b/res/values-vi/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-vi/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-zh-rCN/config.xml b/res/values-zh-rCN/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-zh-rCN/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-zh-rHK/config.xml b/res/values-zh-rHK/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-zh-rHK/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-zh-rTW/config.xml b/res/values-zh-rTW/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-zh-rTW/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values-zu/config.xml b/res/values-zu/config.xml
deleted file mode 100644
index 509a3c8..0000000
--- a/res/values-zu/config.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright (C) 2009 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.
- -->
-
-<!-- NOTE: Many variables that used to be in this file have been migrated to
- CarrierConfigManager.java. Please consider whether new variables belong
- there before adding to this file. Variables here should be more closely
- related to devices than to networks. -->
-
-<!-- Phone app resources that may need to be customized
- for different hardware or product builds. -->
-
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
- <string name="system_visual_voicemail_client" msgid="1787338073957698459"></string>
-</resources>
diff --git a/res/values/config.xml b/res/values/config.xml
index 8c36b1a..d4e4c79 100644
--- a/res/values/config.xml
+++ b/res/values/config.xml
@@ -209,7 +209,7 @@
<!-- The package to handle visual voicemail if the default dialer or the package
CarrierConfigManager.KEY_CARRIER_VVM_PACKAGE_NAME_STRING does not handle it -->
- <string name="system_visual_voicemail_client"></string>
+ <string name="system_visual_voicemail_client" translatable="false"/>
<!-- Flag to enable VVM3 visual voicemail. VVM3 is used by Verizon Wireless. -->
<bool name="vvm3_enabled">false</bool>
@@ -236,10 +236,10 @@
<bool name="config_support_rtt">false</bool>
<!-- String indicating the package name of the device ImsService implementation for MMTEL. -->
- <string name="config_ims_mmtel_package"></string>
+ <string name="config_ims_mmtel_package" translatable="false"/>
<!-- String indicating the package name of the device ImsService implementation for RCS. -->
- <string name="config_ims_rcs_package"></string>
+ <string name="config_ims_rcs_package" translatable="false"/>
<!-- The package name for the platform number verification supplier app. -->
<string name="platform_number_verification_package" translatable="false"></string>
@@ -257,6 +257,14 @@
audio stream which the remote party will be able to hear. -->
<bool name="config_support_telephony_audio_device">false</bool>
+ <string-array translatable="false" name="config_volte_provision_error_on_publish_response">
+ <item>403 not authorized for presence</item>
+ </string-array>
+
+ <string-array translatable="false" name="config_rcs_provision_error_on_publish_response">
+ <item>404 not found</item>
+ </string-array>
+
<!-- The country list that shortcut view can be enabled. -->
<string-array name="config_countries_to_enable_shortcut_view" translatable="false">
</string-array>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index 6ac95c3..39daea8 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -1843,8 +1843,6 @@
<string name="messageCallBarring">Enter password</string>
<!-- Call barring settings screen, section heading -->
<string name="call_barring_settings">Call barring settings</string>
- <!-- Call barring settings screen, deactivate all call barring settings -->
- <string name="call_barring_deactivate_all_no_password">Deactivate all call barring settings?</string>
<!-- In-call screen: error message shown when the user attempts to place a call, but the network
does not have enough resources (e.g. it is busy) and the call cannot be placed. -->
<string name="callFailed_NetworkBusy">Network is busy. Please try your call again later.</string>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index d131bd8..e8a0bed 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -260,7 +260,7 @@
<item name="android:navigationBarColor">@android:color/transparent</item>
<item name="android:homeAsUpIndicator">@drawable/ic_back_arrow</item>
<item name="emergencyButtonBackgroundColor">#3cffffff</item>
- <item name="dialpadTheme">@style/Dialpad_DarkTransparent</item>
+ <item name="dialpadTheme">@style/Dialpad_DarkTransparent.Emergency</item>
</style>
<style name="EmergencyDialerThemeDark" parent="@style/EmergencyDialerTheme">
@@ -268,7 +268,15 @@
<item name="android:textColor">?android:attr/textColorPrimaryInverse</item>
<item name="emergencyButtonBackgroundColor">#19414549</item>
<item name="android:colorControlHighlight">#40000000</item>
- <item name="dialpadTheme">@style/Dialpad_LightTransparent</item>
+ <item name="dialpadTheme">@style/Dialpad_LightTransparent.Emergency</item>
+ </style>
+
+ <style name="Dialpad_LightTransparent.Emergency">
+ <item name="dialpad_delete_padding">16dp</item>
+ </style>
+
+ <style name="Dialpad_DarkTransparent.Emergency">
+ <item name="dialpad_delete_padding">16dp</item>
</style>
<style name="EmergencyDialerAlertDialogTheme"
diff --git a/sip/src/com/android/services/telephony/sip/SipSettings.java b/sip/src/com/android/services/telephony/sip/SipSettings.java
index ded16df..700fe81 100644
--- a/sip/src/com/android/services/telephony/sip/SipSettings.java
+++ b/sip/src/com/android/services/telephony/sip/SipSettings.java
@@ -42,6 +42,7 @@
import com.android.phone.R;
import java.io.IOException;
+import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
import java.util.LinkedHashMap;
@@ -238,7 +239,7 @@
}
private void processActiveProfilesFromSipService() {
- SipProfile[] activeList = {};
+ List<SipProfile> activeList = new ArrayList<>();
try {
activeList = mSipManager.getListOfProfiles();
} catch (SipException e) {
diff --git a/sip/src/com/android/services/telephony/sip/SipUtil.java b/sip/src/com/android/services/telephony/sip/SipUtil.java
index ff38754..828174e 100644
--- a/sip/src/com/android/services/telephony/sip/SipUtil.java
+++ b/sip/src/com/android/services/telephony/sip/SipUtil.java
@@ -29,12 +29,11 @@
import android.telecom.PhoneAccount;
import android.telecom.PhoneAccountHandle;
import android.telecom.TelecomManager;
+import android.telephony.TelephonyManager;
import android.text.TextUtils;
import android.util.Log;
import com.android.phone.PhoneGlobals;
-import com.android.phone.R;
-import com.android.server.sip.SipService;
import java.io.IOException;
import java.util.ArrayList;
@@ -46,6 +45,7 @@
"com.android.services.telephony.sip.incoming_call_intent";
static final String EXTRA_PHONE_ACCOUNT =
"com.android.services.telephony.sip.phone_account";
+ static final String PHONE_PACKAGE = "com.android.phone";
private SipUtil() {
}
@@ -53,9 +53,9 @@
public static boolean isVoipSupported(Context context) {
return SipManager.isVoipSupported(context) &&
context.getResources().getBoolean(
- com.android.internal.R.bool.config_built_in_sip_phone) &&
- context.getResources().getBoolean(
- com.android.internal.R.bool.config_voice_capable);
+ com.android.internal.R.bool.config_built_in_sip_phone)
+ && ((TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE))
+ .isVoiceCapable();
}
static PendingIntent createIncomingCallPendingIntent(
@@ -190,7 +190,10 @@
// Migrate SIP database from DE->CE storage if the device has just upgraded.
possiblyMigrateSipDb(phoneGlobalsContext);
// Wait until boot complete to start SIP so that it has access to CE storage.
- SipService.start(phoneGlobalsContext);
+ Intent startSipIntent = new Intent();
+ startSipIntent.setAction(SipManager.ACTION_START_SIP);
+ startSipIntent.setPackage(PHONE_PACKAGE);
+ phoneGlobalsContext.startService(startSipIntent);
}
/**
diff --git a/sip/src/com/android/services/telephony/sip/components/TelephonySipService.java b/sip/src/com/android/services/telephony/sip/components/TelephonySipService.java
new file mode 100644
index 0000000..5b863b1
--- /dev/null
+++ b/sip/src/com/android/services/telephony/sip/components/TelephonySipService.java
@@ -0,0 +1,43 @@
+/*
+ * Copyright (C) 2020 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.
+ */
+package com.android.services.telephony.sip.components;
+
+import android.app.Service;
+import android.content.Intent;
+import android.net.sip.SipManager;
+import android.os.IBinder;
+
+import com.android.server.sip.SipService;
+
+/**
+ * This class represents telephony SIP service which handle start SIP service requests from
+ * Telephony.
+ */
+public class TelephonySipService extends Service {
+ @Override
+ public int onStartCommand(Intent intent, int flags, int startId) {
+ if ((intent != null)
+ && SipManager.ACTION_START_SIP.equals(intent.getAction())) {
+ SipService.start(this);
+ }
+ return START_STICKY;
+ }
+
+ @Override
+ public IBinder onBind(Intent intent) {
+ return null;
+ }
+}
diff --git a/src/com/android/phone/CallBarringDeselectAllPreference.java b/src/com/android/phone/CallBarringDeselectAllPreference.java
index e9310f8..7191937 100644
--- a/src/com/android/phone/CallBarringDeselectAllPreference.java
+++ b/src/com/android/phone/CallBarringDeselectAllPreference.java
@@ -19,12 +19,9 @@
import android.content.Context;
import android.os.Bundle;
import android.util.AttributeSet;
-import android.util.Log;
import android.view.View;
import android.widget.EditText;
-import com.android.internal.telephony.Phone;
-import com.android.internal.telephony.imsphone.ImsPhone;
import com.android.phone.settings.fdn.EditPinPreference;
/**
@@ -34,9 +31,6 @@
private static final String LOG_TAG = "CallBarringDeselectAllPreference";
private static final boolean DBG = (PhoneGlobals.DBG_LEVEL >= 2);
- private boolean mShowPassword;
- private Phone mPhone;
-
/**
* CallBarringDeselectAllPreference constructor.
*
@@ -49,28 +43,10 @@
@Override
protected void showDialog(Bundle state) {
- // Finds out if the password field should be shown or not.
- ImsPhone imsPhone = mPhone != null ? (ImsPhone) mPhone.getImsPhone() : null;
- mShowPassword = !(imsPhone != null && imsPhone.isUtEnabled());
-
- // Selects dialog message depending on if the password field is shown or not.
- setDialogMessage(getContext().getString(mShowPassword
- ? R.string.messageCallBarring : R.string.call_barring_deactivate_all_no_password));
-
- if (DBG) {
- Log.d(LOG_TAG, "showDialog: mShowPassword: " + mShowPassword);
- }
-
+ setDialogMessage(getContext().getString(R.string.messageCallBarring));
super.showDialog(state);
}
- void init(Phone phone) {
- if (DBG) {
- Log.d(LOG_TAG, "init: phoneId = " + phone.getPhoneId());
- }
- mPhone = phone;
- }
-
@Override
protected void onBindDialogView(View view) {
super.onBindDialogView(view);
@@ -78,20 +54,7 @@
final EditText editText = (EditText) view.findViewById(android.R.id.edit);
if (editText != null) {
// Hide the input-text-line if the password is not shown.
- editText.setVisibility(mShowPassword ? View.VISIBLE : View.GONE);
+ editText.setVisibility(View.VISIBLE);
}
}
-
- @Override
- protected boolean needInputMethod() {
- // Input method should only be displayed if the password-field is shown.
- return mShowPassword;
- }
-
- /**
- * Returns whether the password field is shown.
- */
- boolean isPasswordShown() {
- return mShowPassword;
- }
}
diff --git a/src/com/android/phone/CallBarringEditPreference.java b/src/com/android/phone/CallBarringEditPreference.java
index edff1e3..4541926 100644
--- a/src/com/android/phone/CallBarringEditPreference.java
+++ b/src/com/android/phone/CallBarringEditPreference.java
@@ -38,7 +38,6 @@
import com.android.internal.telephony.CommandException;
import com.android.internal.telephony.Phone;
import com.android.internal.telephony.PhoneFactory;
-import com.android.internal.telephony.imsphone.ImsPhone;
import com.android.phone.settings.fdn.EditPinPreference;
import java.lang.ref.WeakReference;
@@ -57,10 +56,7 @@
private CharSequence mDisableText;
private CharSequence mSummaryOn;
private CharSequence mSummaryOff;
- private CharSequence mDialogMessageEnabled;
- private CharSequence mDialogMessageDisabled;
private int mButtonClicked;
- private boolean mShowPassword;
private final MyHandler mHandler = new MyHandler(this);
private Phone mPhone;
private TimeConsumingPreferenceListener mTcpListener;
@@ -77,9 +73,9 @@
super(context, attrs);
// Get the summary settings, use CheckBoxPreference as the standard.
TypedArray typedArray = context.obtainStyledAttributes(attrs,
- android.R.styleable.CheckBoxPreference, 0, 0);
- mSummaryOn = typedArray.getString(android.R.styleable.CheckBoxPreference_summaryOn);
- mSummaryOff = typedArray.getString(android.R.styleable.CheckBoxPreference_summaryOff);
+ R.styleable.CheckBoxPreference, 0, 0);
+ mSummaryOn = typedArray.getString(R.styleable.CheckBoxPreference_summaryOn);
+ mSummaryOff = typedArray.getString(R.styleable.CheckBoxPreference_summaryOff);
mDisableText = context.getText(R.string.disable);
mEnableText = context.getText(R.string.enable);
typedArray.recycle();
@@ -90,10 +86,6 @@
typedArray = context.obtainStyledAttributes(attrs,
R.styleable.CallBarringEditPreference, 0, R.style.EditPhoneNumberPreference);
mFacility = typedArray.getString(R.styleable.CallBarringEditPreference_facility);
- mDialogMessageEnabled = typedArray.getString(
- R.styleable.CallBarringEditPreference_dialogMessageEnabledNoPwd);
- mDialogMessageDisabled = typedArray.getString(
- R.styleable.CallBarringEditPreference_dialogMessageDisabledNoPwd);
typedArray.recycle();
}
@@ -130,29 +122,8 @@
}
@Override
- protected boolean needInputMethod() {
- // Input method should only be displayed if the password-field is shown.
- return mShowPassword;
- }
-
- void setInputMethodNeeded(boolean needed) {
- mShowPassword = needed;
- }
-
- @Override
protected void showDialog(Bundle state) {
- setShowPassword();
- if (mShowPassword) {
- setDialogMessage(getContext().getString(R.string.messageCallBarring));
- } else {
- setDialogMessage(mIsActivated ? mDialogMessageEnabled : mDialogMessageDisabled);
- }
-
- if (DBG) {
- Log.d(LOG_TAG, "showDialog: mShowPassword: " + mShowPassword
- + ", mIsActivated: " + mIsActivated);
- }
-
+ setDialogMessage(getContext().getString(R.string.messageCallBarring));
super.showDialog(state);
}
@@ -204,8 +175,7 @@
editText.setTransformationMethod(PasswordTransformationMethod.getInstance());
editText.setKeyListener(DigitsKeyListener.getInstance());
- // Hide the input-text-line if the password is not shown.
- editText.setVisibility(mShowPassword ? View.VISIBLE : View.GONE);
+ editText.setVisibility(View.VISIBLE);
}
}
@@ -217,17 +187,14 @@
+ positiveResult);
}
if (mButtonClicked != DialogInterface.BUTTON_NEGATIVE) {
- String password = null;
- if (mShowPassword) {
- password = getEditText().getText().toString();
+ String password = getEditText().getText().toString();
- // Check if the password is valid.
- if (password == null || password.length() != PW_LENGTH) {
- Toast.makeText(getContext(),
- getContext().getString(R.string.call_barring_right_pwd_number),
- Toast.LENGTH_SHORT).show();
- return;
- }
+ // Check if the password is valid.
+ if (password == null || password.length() != PW_LENGTH) {
+ Toast.makeText(getContext(),
+ getContext().getString(R.string.call_barring_right_pwd_number),
+ Toast.LENGTH_SHORT).show();
+ return;
}
if (DBG) {
@@ -254,11 +221,6 @@
notifyDependencyChange(shouldDisableDependents());
}
- private void setShowPassword() {
- ImsPhone imsPhone = mPhone != null ? (ImsPhone) mPhone.getImsPhone() : null;
- mShowPassword = !(imsPhone != null && imsPhone.isUtEnabled());
- }
-
@Override
public boolean shouldDisableDependents() {
return mIsActivated;
@@ -310,16 +272,6 @@
pref.mTcpListener.onFinished(pref, false);
} else {
pref.mTcpListener.onFinished(pref, true);
- ImsPhone imsPhone = pref.mPhone != null
- ? (ImsPhone) pref.mPhone.getImsPhone() : null;
- if (!pref.mShowPassword && (imsPhone == null || !imsPhone.isUtEnabled())) {
- // Re-enable password when rejected from NW and modem would perform CSFB
- pref.mShowPassword = true;
- if (DBG) {
- Log.d(LOG_TAG,
- "handleGetCallBarringResponse: mShowPassword changed for CSFB");
- }
- }
}
// Unsuccessful query for call barring.
diff --git a/src/com/android/phone/CallNotifier.java b/src/com/android/phone/CallNotifier.java
index dab04f0..f9938ce 100644
--- a/src/com/android/phone/CallNotifier.java
+++ b/src/com/android/phone/CallNotifier.java
@@ -558,7 +558,8 @@
public void updatePhoneStateListeners(boolean isRefresh, int updateType, int subIdToUpdate) {
List<SubscriptionInfo> subInfos = SubscriptionController.getInstance()
- .getActiveSubscriptionInfoList(mApplication.getOpPackageName());
+ .getActiveSubscriptionInfoList(mApplication.getOpPackageName(),
+ null);
// Sort sub id list based on slot id, so that CFI/MWI notifications will be updated for
// slot 0 first then slot 1. This is needed to ensure that when CFI or MWI is enabled for
@@ -615,7 +616,7 @@
for (int i = 0; i < subInfos.size(); i++) {
int subId = subInfos.get(i).getSubscriptionId();
if (!mPhoneStateListeners.containsKey(subId)) {
- CallNotifierPhoneStateListener listener = new CallNotifierPhoneStateListener();
+ CallNotifierPhoneStateListener listener = new CallNotifierPhoneStateListener(subId);
mTelephonyManager.createForSubscriptionId(subId).listen(listener,
PhoneStateListener.LISTEN_MESSAGE_WAITING_INDICATOR
| PhoneStateListener.LISTEN_CALL_FORWARDING_INDICATOR);
@@ -767,8 +768,11 @@
};
private class CallNotifierPhoneStateListener extends PhoneStateListener {
- public CallNotifierPhoneStateListener() {
+ private final int mSubId;
+
+ CallNotifierPhoneStateListener(int subId) {
super();
+ this.mSubId = subId;
}
@Override
diff --git a/src/com/android/phone/CarrierConfigLoader.java b/src/com/android/phone/CarrierConfigLoader.java
index 49f690a..3812b2f 100644
--- a/src/com/android/phone/CarrierConfigLoader.java
+++ b/src/com/android/phone/CarrierConfigLoader.java
@@ -57,13 +57,8 @@
import com.android.internal.telephony.SubscriptionInfoUpdater;
import com.android.internal.telephony.TelephonyPermissions;
import com.android.internal.telephony.util.ArrayUtils;
-import com.android.internal.util.FastXmlSerializer;
import com.android.internal.util.IndentingPrintWriter;
-import org.xmlpull.v1.XmlPullParser;
-import org.xmlpull.v1.XmlPullParserException;
-import org.xmlpull.v1.XmlPullParserFactory;
-
import java.io.File;
import java.io.FileDescriptor;
import java.io.FileInputStream;
@@ -80,7 +75,6 @@
/**
* CarrierConfigLoader binds to privileged carrier apps to fetch carrier config overlays.
*/
-
public class CarrierConfigLoader extends ICarrierConfigLoader.Stub {
private static final String LOG_TAG = "CarrierConfigLoader";
@@ -149,10 +143,8 @@
private static final int BIND_TIMEOUT_MILLIS = 30000;
- // Tags used for saving and restoring XML documents.
- private static final String TAG_DOCUMENT = "carrier_config";
- private static final String TAG_VERSION = "package_version";
- private static final String TAG_BUNDLE = "bundle_data";
+ // Keys used for saving and restoring config bundle from file.
+ private static final String KEY_VERSION = "__carrier_config_package_version__";
private static final String OVERRIDE_PACKAGE_ADDITION = "-override";
@@ -793,27 +785,14 @@
outFile = new FileOutputStream(
new File(mContext.getFilesDir(),
getFilenameForConfig(packageName, extraString, iccid, cid)));
- FastXmlSerializer out = new FastXmlSerializer();
- out.setOutput(outFile, "utf-8");
- out.startDocument("utf-8", true);
- out.startTag(null, TAG_DOCUMENT);
- out.startTag(null, TAG_VERSION);
- out.text(version);
- out.endTag(null, TAG_VERSION);
- out.startTag(null, TAG_BUNDLE);
- config.saveToXml(out);
- out.endTag(null, TAG_BUNDLE);
- out.endTag(null, TAG_DOCUMENT);
- out.endDocument();
- out.flush();
+ config.putString(KEY_VERSION, version);
+ config.writeToStream(outFile);
+ outFile.flush();
outFile.close();
}
catch (IOException e) {
loge(e.toString());
}
- catch (XmlPullParserException e) {
- loge(e.toString());
- }
}
/**
@@ -858,24 +837,16 @@
file = new File(mContext.getFilesDir(),
getFilenameForConfig(packageName, extraString, iccid, cid));
inFile = new FileInputStream(file);
- XmlPullParser parser = XmlPullParserFactory.newInstance().newPullParser();
- parser.setInput(inFile, "utf-8");
- int event;
- while (((event = parser.next()) != XmlPullParser.END_DOCUMENT)) {
+ restoredBundle = PersistableBundle.readFromStream(inFile);
+ String savedVersion = restoredBundle.getString(KEY_VERSION);
+ restoredBundle.remove(KEY_VERSION);
- if (event == XmlPullParser.START_TAG && TAG_VERSION.equals(parser.getName())) {
- String savedVersion = parser.nextText();
- if (!version.equals(savedVersion)) {
- loge("Saved version mismatch: " + version + " vs " + savedVersion);
- break;
- }
- }
-
- if (event == XmlPullParser.START_TAG && TAG_BUNDLE.equals(parser.getName())) {
- restoredBundle = PersistableBundle.restoreFromXml(parser);
- }
+ if (!version.equals(savedVersion)) {
+ loge("Saved version mismatch: " + version + " vs " + savedVersion);
+ restoredBundle = null;
}
+
inFile.close();
}
catch (FileNotFoundException e) {
@@ -883,9 +854,6 @@
// an override file during boot and should not be treated as an error.
if (file != null) log("File not found: " + file.getPath());
}
- catch (XmlPullParserException e) {
- loge(e.toString());
- }
catch (IOException e) {
loge(e.toString());
}
@@ -967,8 +935,14 @@
@Override
public @NonNull PersistableBundle getConfigForSubId(int subId, String callingPackage) {
- if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mContext, subId, callingPackage, "getCarrierConfig")) {
+ return getConfigForSubIdWithFeature(subId, callingPackage, null);
+ }
+
+ @Override
+ public @NonNull PersistableBundle getConfigForSubIdWithFeature(int subId, String callingPackage,
+ String callingFeatureId) {
+ if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mContext, subId, callingPackage,
+ callingFeatureId, "getCarrierConfig")) {
return new PersistableBundle();
}
@@ -1080,6 +1054,7 @@
case IccCardConstants.INTENT_VALUE_ICC_CARD_IO_ERROR:
case IccCardConstants.INTENT_VALUE_ICC_CARD_RESTRICTED:
case IccCardConstants.INTENT_VALUE_ICC_UNKNOWN:
+ case IccCardConstants.INTENT_VALUE_ICC_NOT_READY:
mHandler.sendMessage(mHandler.obtainMessage(EVENT_CLEAR_CONFIG, phoneId, -1));
break;
case IccCardConstants.INTENT_VALUE_ICC_LOADED:
diff --git a/src/com/android/phone/EmergencyDialer.java b/src/com/android/phone/EmergencyDialer.java
index 7531aca..119c71b 100644
--- a/src/com/android/phone/EmergencyDialer.java
+++ b/src/com/android/phone/EmergencyDialer.java
@@ -45,7 +45,7 @@
import android.telecom.TelecomManager;
import android.telephony.CarrierConfigManager;
import android.telephony.PhoneNumberUtils;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import android.telephony.ServiceState;
import android.telephony.SubscriptionManager;
import android.telephony.TelephonyManager;
diff --git a/src/com/android/phone/GsmUmtsCallBarringOptions.java b/src/com/android/phone/GsmUmtsCallBarringOptions.java
index 3c9cd84..30e9b5c 100644
--- a/src/com/android/phone/GsmUmtsCallBarringOptions.java
+++ b/src/com/android/phone/GsmUmtsCallBarringOptions.java
@@ -37,7 +37,6 @@
import com.android.internal.telephony.CommandsInterface;
import com.android.internal.telephony.GsmCdmaPhone;
import com.android.internal.telephony.Phone;
-import com.android.internal.telephony.imsphone.ImsPhone;
import com.android.phone.settings.fdn.EditPinPreference;
import java.util.ArrayList;
@@ -75,7 +74,6 @@
private static final String DIALOG_PW_ENTRY_KEY = "dialog_pw_enter_key";
private static final String KEY_STATUS = "toggle";
private static final String PREFERENCE_ENABLED_KEY = "PREFERENCE_ENABLED";
- private static final String PREFERENCE_SHOW_PASSWORD_KEY = "PREFERENCE_SHOW_PASSWORD";
private static final String SAVED_BEFORE_LOAD_COMPLETED_KEY = "PROGRESS_SHOWING";
private CallBarringEditPreference mButtonBAOC;
@@ -141,16 +139,13 @@
return;
}
- String password = null;
- if (mButtonDisableAll.isPasswordShown()) {
- password = mButtonDisableAll.getText();
- // Validate the length of password first, before submitting it to the
- // RIL for CB disable.
- if (!validatePassword(password)) {
- mButtonDisableAll.setText("");
- displayMessage(R.string.call_barring_right_pwd_number);
- return;
- }
+ String password = mButtonDisableAll.getText();
+ // Validate the length of password first, before submitting it to the
+ // RIL for CB disable.
+ if (!validatePassword(password)) {
+ mButtonDisableAll.setText("");
+ displayMessage(R.string.call_barring_right_pwd_number);
+ return;
}
// Submit the disable all request
@@ -417,34 +412,18 @@
mPreferences.add(mButtonBAIC);
mPreferences.add(mButtonBAICr);
- // Find out if password is currently used.
- boolean usePassword = true;
- boolean useDisableaAll = true;
-
- ImsPhone imsPhone = mPhone != null ? (ImsPhone) mPhone.getImsPhone() : null;
- if (imsPhone != null && imsPhone.isUtEnabled()) {
- usePassword = false;
- useDisableaAll = false;
- }
-
// Find out if the sim card is ready.
boolean isSimReady = TelephonyManager.from(this).getSimState(
SubscriptionManager.getSlotIndex(mPhone.getSubId()))
== TelephonyManager.SIM_STATE_READY;
- // Deactivate all option is unavailable when sim card is not ready or Ut is enabled.
- if (isSimReady && useDisableaAll) {
+ // Deactivate all option and Change password option are unavailable
+ // when sim card is not ready.
+ if (isSimReady) {
mButtonDisableAll.setEnabled(true);
- mButtonDisableAll.init(mPhone);
- } else {
- mButtonDisableAll.setEnabled(false);
- }
-
- // Change password option is unavailable when sim card is not ready or when the password is
- // not used.
- if (isSimReady && usePassword) {
mButtonChangePW.setEnabled(true);
} else {
+ mButtonDisableAll.setEnabled(false);
mButtonChangePW.setEnabled(false);
mButtonChangePW.setSummary(R.string.call_barring_change_pwd_description_disabled);
}
@@ -472,8 +451,6 @@
pref.handleCallBarringResult(bundle.getBoolean(KEY_STATUS));
pref.init(this, true, mPhone);
pref.setEnabled(bundle.getBoolean(PREFERENCE_ENABLED_KEY, pref.isEnabled()));
- pref.setInputMethodNeeded(bundle.getBoolean(PREFERENCE_SHOW_PASSWORD_KEY,
- pref.needInputMethod()));
}
}
mPwChangeState = mIcicle.getInt(PW_CHANGE_STATE_KEY);
@@ -513,7 +490,6 @@
Bundle bundle = new Bundle();
bundle.putBoolean(KEY_STATUS, pref.mIsActivated);
bundle.putBoolean(PREFERENCE_ENABLED_KEY, pref.isEnabled());
- bundle.putBoolean(PREFERENCE_SHOW_PASSWORD_KEY, pref.needInputMethod());
outState.putParcelable(pref.getKey(), bundle);
}
outState.putInt(PW_CHANGE_STATE_KEY, mPwChangeState);
diff --git a/src/com/android/phone/IccPanel.java b/src/com/android/phone/IccPanel.java
index be182233..73dd8bc 100644
--- a/src/com/android/phone/IccPanel.java
+++ b/src/com/android/phone/IccPanel.java
@@ -74,13 +74,13 @@
@Override
protected void onStart() {
super.onStart();
- mStatusBarManager.disable(StatusBarManager.DISABLE_EXPAND);
+ mStatusBarManager.setDisabledForSimNetworkLock(true);
}
@Override
public void onStop() {
super.onStop();
- mStatusBarManager.disable(StatusBarManager.DISABLE_NONE);
+ mStatusBarManager.setDisabledForSimNetworkLock(false);
}
public boolean onKeyDown(int keyCode, KeyEvent event) {
diff --git a/src/com/android/phone/ImsRcsController.java b/src/com/android/phone/ImsRcsController.java
index 06d2367..9d9010a 100644
--- a/src/com/android/phone/ImsRcsController.java
+++ b/src/com/android/phone/ImsRcsController.java
@@ -23,16 +23,21 @@
import android.os.ServiceManager;
import android.os.ServiceSpecificException;
import android.telephony.ims.ImsException;
+import android.telephony.ims.RegistrationManager;
import android.telephony.ims.aidl.IImsCapabilityCallback;
import android.telephony.ims.aidl.IImsRcsController;
+import android.telephony.ims.aidl.IImsRegistrationCallback;
import android.telephony.ims.aidl.IRcsUceControllerCallback;
import android.telephony.ims.feature.RcsFeature;
import android.telephony.ims.stub.ImsRegistrationImplBase;
import android.util.Log;
+import com.android.ims.ImsManager;
import com.android.ims.RcsFeatureManager;
+import com.android.internal.telephony.IIntegerConsumer;
import com.android.internal.telephony.Phone;
import com.android.internal.telephony.imsphone.ImsPhone;
+import com.android.services.telephony.rcs.TelephonyRcsService;
import java.util.List;
@@ -46,6 +51,7 @@
private static ImsRcsController sInstance;
private PhoneGlobals mApp;
+ private TelephonyRcsService mRcsService;
/**
* Initialize the singleton ImsRcsController instance.
@@ -70,6 +76,86 @@
}
/**
+ * Register a IImsRegistrationCallback to receive IMS network registration state.
+ */
+ @Override
+ public void registerImsRegistrationCallback(int subId, IImsRegistrationCallback callback)
+ throws RemoteException {
+ enforceReadPrivilegedPermission("registerImsRegistrationCallback");
+ final long token = Binder.clearCallingIdentity();
+ try {
+ getRcsFeatureManager(subId).registerImsRegistrationCallback(callback);
+ } catch (com.android.ims.ImsException e) {
+ Log.e(TAG, "registerImsRegistrationCallback: sudId=" + subId + ", " + e.getMessage());
+ throw new ServiceSpecificException(e.getCode());
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ /**
+ * Removes an existing {@link RegistrationCallback}.
+ */
+ @Override
+ public void unregisterImsRegistrationCallback(int subId, IImsRegistrationCallback callback) {
+ enforceReadPrivilegedPermission("unregisterImsRegistrationCallback");
+ final long token = Binder.clearCallingIdentity();
+ try {
+ getRcsFeatureManager(subId).unregisterImsRegistrationCallback(callback);
+ } catch (ServiceSpecificException e) {
+ Log.e(TAG, "unregisterImsRegistrationCallback: error=" + e.errorCode);
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ /**
+ * Get the IMS service registration state for the RcsFeature associated with this sub id.
+ */
+ @Override
+ public void getImsRcsRegistrationState(int subId, IIntegerConsumer consumer) {
+ enforceReadPrivilegedPermission("getImsRcsRegistrationState");
+ final long token = Binder.clearCallingIdentity();
+ try {
+ getImsPhone(subId).getImsRcsRegistrationState(regState -> {
+ try {
+ consumer.accept((regState == null)
+ ? RegistrationManager.REGISTRATION_STATE_NOT_REGISTERED : regState);
+ } catch (RemoteException e) {
+ Log.w(TAG, "getImsRcsRegistrationState: callback is not available.");
+ }
+ });
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ /**
+ * Gets the Transport Type associated with the current IMS RCS registration.
+ */
+ @Override
+ public void getImsRcsRegistrationTransportType(int subId, IIntegerConsumer consumer) {
+ enforceReadPrivilegedPermission("getImsRcsRegistrationTransportType");
+ final long token = Binder.clearCallingIdentity();
+ try {
+ getImsPhone(subId).getImsRcsRegistrationTech(regTech -> {
+ // Convert registration tech from ImsRegistrationImplBase -> RegistrationManager
+ int regTechConverted = (regTech == null)
+ ? ImsRegistrationImplBase.REGISTRATION_TECH_NONE : regTech;
+ regTechConverted = RegistrationManager.IMS_REG_TO_ACCESS_TYPE_MAP.get(
+ regTechConverted);
+ try {
+ consumer.accept(regTechConverted);
+ } catch (RemoteException e) {
+ Log.w(TAG, "getImsRcsRegistrationTransportType: callback is not available.");
+ }
+ });
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ /**
* Register a capability callback which will provide RCS availability updates for the
* subscription specified.
*
@@ -202,13 +288,17 @@
}
/**
- * Retrieve RcsFeatureManager instance.
+ * Retrieve ImsPhone instance.
*
* @param subId the subscription ID
- * @return The RcsFeatureManager instance
- * @throws SecurityException if getting Phone or RcsFeatureManager instance failed.
+ * @return The ImsPhone instance
+ * @throws ServiceSpecificException if getting ImsPhone instance failed.
*/
- private RcsFeatureManager getRcsFeatureManager(int subId) {
+ private ImsPhone getImsPhone(int subId) {
+ if (!ImsManager.isImsSupportedOnDevice(mApp)) {
+ throw new ServiceSpecificException(ImsException.CODE_ERROR_UNSUPPORTED_OPERATION,
+ "IMS is not available on device.");
+ }
Phone phone = PhoneGlobals.getPhone(subId);
if (phone == null) {
throw new ServiceSpecificException(ImsException.CODE_ERROR_INVALID_SUBSCRIPTION,
@@ -216,7 +306,32 @@
}
ImsPhone imsPhone = (ImsPhone) phone.getImsPhone();
if (imsPhone == null) {
+ throw new ServiceSpecificException(ImsException.CODE_ERROR_SERVICE_UNAVAILABLE,
+ "Cannot find ImsPhone instance: " + subId);
+ }
+ return imsPhone;
+ }
+
+ /**
+ * Retrieve RcsFeatureManager instance.
+ *
+ * @param subId the subscription ID
+ * @return The RcsFeatureManager instance
+ * @throws ServiceSpecificException if getting RcsFeatureManager instance failed.
+ */
+ private RcsFeatureManager getRcsFeatureManager(int subId) {
+ if (!ImsManager.isImsSupportedOnDevice(mApp)) {
throw new ServiceSpecificException(ImsException.CODE_ERROR_UNSUPPORTED_OPERATION,
+ "IMS is not available on device.");
+ }
+ Phone phone = PhoneGlobals.getPhone(subId);
+ if (phone == null) {
+ throw new ServiceSpecificException(ImsException.CODE_ERROR_INVALID_SUBSCRIPTION,
+ "Invalid subscription Id: " + subId);
+ }
+ ImsPhone imsPhone = (ImsPhone) phone.getImsPhone();
+ if (imsPhone == null) {
+ throw new ServiceSpecificException(ImsException.CODE_ERROR_SERVICE_UNAVAILABLE,
"Cannot find ImsPhone instance: " + subId);
}
RcsFeatureManager rcsFeatureManager = imsPhone.getRcsManager();
@@ -226,4 +341,8 @@
}
return rcsFeatureManager;
}
+
+ void setRcsService(TelephonyRcsService rcsService) {
+ mRcsService = rcsService;
+ }
}
diff --git a/src/com/android/phone/NumberVerificationManager.java b/src/com/android/phone/NumberVerificationManager.java
index 9ec16f8..2298d40 100644
--- a/src/com/android/phone/NumberVerificationManager.java
+++ b/src/com/android/phone/NumberVerificationManager.java
@@ -135,7 +135,7 @@
}
// make sure at least one phone is registered for voice
- if (phone.getServiceState().getVoiceRegState() == ServiceState.STATE_IN_SERVICE) {
+ if (phone.getServiceState().getState() == ServiceState.STATE_IN_SERVICE) {
isAnyPhoneVoiceRegistered = true;
}
// make sure at least one phone has room for an incoming call.
diff --git a/src/com/android/phone/PhoneGlobals.java b/src/com/android/phone/PhoneGlobals.java
index 1371674..b0e0105 100644
--- a/src/com/android/phone/PhoneGlobals.java
+++ b/src/com/android/phone/PhoneGlobals.java
@@ -71,6 +71,7 @@
import com.android.internal.util.IndentingPrintWriter;
import com.android.phone.settings.SettingsConstants;
import com.android.phone.vvm.CarrierVvmPackageInstalledReceiver;
+import com.android.services.telephony.rcs.TelephonyRcsService;
import com.android.services.telephony.sip.SipAccountRegistry;
import com.android.services.telephony.sip.SipUtil;
@@ -149,6 +150,7 @@
CallerInfoCache callerInfoCache;
NotificationMgr notificationMgr;
ImsResolver mImsResolver;
+ TelephonyRcsService mTelephonyRcsService;
public PhoneInterfaceManager phoneMgr;
public ImsRcsController imsRcsController;
CarrierConfigLoader configLoader;
@@ -303,8 +305,8 @@
// Cache the "voice capable" flag.
// This flag currently comes from a resource (which is
// overrideable on a per-product basis):
- sVoiceCapable =
- getResources().getBoolean(com.android.internal.R.bool.config_voice_capable);
+ sVoiceCapable = ((TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE))
+ .isVoiceCapable();
// ...but this might eventually become a PackageManager "system
// feature" instead, in which case we'd do something like:
// sVoiceCapable =
@@ -372,6 +374,11 @@
imsRcsController = ImsRcsController.init(this);
+ if (getPackageManager().hasSystemFeature(PackageManager.FEATURE_TELEPHONY_IMS)) {
+ mTelephonyRcsService = new TelephonyRcsService(this);
+ imsRcsController.setRcsService(mTelephonyRcsService);
+ }
+
configLoader = CarrierConfigLoader.init(this);
// Create the CallNotifier singleton, which handles
@@ -403,7 +410,7 @@
IntentFilter sipIntentFilter = new IntentFilter(Intent.ACTION_BOOT_COMPLETED);
sipIntentFilter.addAction(SipManager.ACTION_SIP_SERVICE_UP);
sipIntentFilter.addAction(SipManager.ACTION_SIP_CALL_OPTION_CHANGED);
- sipIntentFilter.addAction(SipManager.ACTION_SIP_REMOVE_PHONE);
+ sipIntentFilter.addAction(SipManager.ACTION_SIP_REMOVE_PROFILE);
registerReceiver(mSipReceiver, sipIntentFilter);
mCarrierVvmPackageInstalledReceiver.register(this);
@@ -467,7 +474,7 @@
}
public PersistableBundle getCarrierConfigForSubId(int subId) {
- return configLoader.getConfigForSubId(subId, getOpPackageName());
+ return configLoader.getConfigForSubIdWithFeature(subId, getOpPackageName(), null);
}
private void registerSettingsObserver() {
@@ -708,7 +715,7 @@
} else if (action.equals(SipManager.ACTION_SIP_SERVICE_UP)
|| action.equals(SipManager.ACTION_SIP_CALL_OPTION_CHANGED)) {
sipAccountRegistry.setup(context);
- } else if (action.equals(SipManager.ACTION_SIP_REMOVE_PHONE)) {
+ } else if (action.equals(SipManager.ACTION_SIP_REMOVE_PROFILE)) {
if (DBG) {
Log.d(LOG_TAG, "SIP_REMOVE_PHONE "
+ intent.getStringExtra(SipManager.EXTRA_LOCAL_URI));
diff --git a/src/com/android/phone/PhoneInterfaceManager.java b/src/com/android/phone/PhoneInterfaceManager.java
index 5f7b627..f11da4b 100755
--- a/src/com/android/phone/PhoneInterfaceManager.java
+++ b/src/com/android/phone/PhoneInterfaceManager.java
@@ -22,6 +22,7 @@
import static com.android.internal.telephony.PhoneConstants.SUBSCRIPTION_KEY;
import android.Manifest.permission;
+import android.annotation.NonNull;
import android.annotation.Nullable;
import android.app.AppOpsManager;
import android.app.PendingIntent;
@@ -67,10 +68,11 @@
import android.telephony.CarrierConfigManager;
import android.telephony.CarrierRestrictionRules;
import android.telephony.CellIdentity;
+import android.telephony.CellIdentityCdma;
+import android.telephony.CellIdentityGsm;
import android.telephony.CellInfo;
import android.telephony.CellInfoGsm;
import android.telephony.CellInfoWcdma;
-import android.telephony.CellLocation;
import android.telephony.ClientRequestStats;
import android.telephony.ICellInfoCallback;
import android.telephony.IccOpenLogicalChannelResponse;
@@ -82,7 +84,6 @@
import android.telephony.PhoneNumberRange;
import android.telephony.RadioAccessFamily;
import android.telephony.RadioAccessSpecifier;
-import android.telephony.Rlog;
import android.telephony.ServiceState;
import android.telephony.SignalStrength;
import android.telephony.SubscriptionInfo;
@@ -94,10 +95,8 @@
import android.telephony.UiccSlotInfo;
import android.telephony.UssdResponse;
import android.telephony.VisualVoicemailSmsFilterSettings;
-import android.telephony.cdma.CdmaCellLocation;
import android.telephony.data.ApnSetting;
import android.telephony.emergency.EmergencyNumber;
-import android.telephony.gsm.GsmCellLocation;
import android.telephony.ims.ImsException;
import android.telephony.ims.ProvisioningManager;
import android.telephony.ims.RegistrationManager;
@@ -110,6 +109,7 @@
import android.telephony.ims.aidl.IImsRegistrationCallback;
import android.telephony.ims.feature.ImsFeature;
import android.telephony.ims.feature.MmTelFeature;
+import android.telephony.ims.feature.RcsFeature;
import android.telephony.ims.stub.ImsConfigImplBase;
import android.telephony.ims.stub.ImsRegistrationImplBase;
import android.text.TextUtils;
@@ -157,6 +157,7 @@
import com.android.internal.telephony.metrics.TelephonyMetrics;
import com.android.internal.telephony.uicc.IccCardApplicationStatus.AppType;
import com.android.internal.telephony.uicc.IccIoResult;
+import com.android.internal.telephony.uicc.IccRecords;
import com.android.internal.telephony.uicc.IccUtils;
import com.android.internal.telephony.uicc.SIMRecords;
import com.android.internal.telephony.uicc.UiccCard;
@@ -172,6 +173,7 @@
import com.android.phone.vvm.RemoteVvmTaskManager;
import com.android.phone.vvm.VisualVoicemailSettingsUtil;
import com.android.phone.vvm.VisualVoicemailSmsFilterConfig;
+import com.android.telephony.Rlog;
import java.io.FileDescriptor;
import java.io.PrintWriter;
@@ -1102,7 +1104,7 @@
request = (MainThreadRequest) msg.obj;
WorkSource ws = (WorkSource) request.argument;
Phone phone = getPhoneFromRequest(request);
- phone.getCellLocation(ws, obtainMessage(EVENT_GET_CELL_LOCATION_DONE, request));
+ phone.getCellIdentity(ws, obtainMessage(EVENT_GET_CELL_LOCATION_DONE, request));
break;
case EVENT_GET_CELL_LOCATION_DONE:
ar = (AsyncResult) msg.obj;
@@ -1112,7 +1114,7 @@
} else {
phone = getPhoneFromRequest(request);
request.result = (phone.getPhoneType() == PhoneConstants.PHONE_TYPE_CDMA)
- ? new CdmaCellLocation() : new GsmCellLocation();
+ ? new CellIdentityCdma() : new CellIdentityGsm();
}
synchronized (request) {
@@ -1452,6 +1454,16 @@
}
}
+ private boolean isImsAvailableOnDevice() {
+ PackageManager pm = getDefaultPhone().getContext().getPackageManager();
+ if (pm == null) {
+ // For some reason package manger is not available.. This will fail internally anyway,
+ // so do not throw error and allow.
+ return true;
+ }
+ return pm.hasSystemFeature(PackageManager.FEATURE_TELEPHONY_IMS, 0);
+ }
+
public void dial(String number) {
dialForSubscriber(getPreferredVoiceSubscription(), number);
}
@@ -1528,29 +1540,16 @@
}
}
- public boolean supplyPin(String pin) {
- return supplyPinForSubscriber(getDefaultSubscription(), pin);
- }
-
public boolean supplyPinForSubscriber(int subId, String pin) {
int [] resultArray = supplyPinReportResultForSubscriber(subId, pin);
return (resultArray[0] == PhoneConstants.PIN_RESULT_SUCCESS) ? true : false;
}
- public boolean supplyPuk(String puk, String pin) {
- return supplyPukForSubscriber(getDefaultSubscription(), puk, pin);
- }
-
public boolean supplyPukForSubscriber(int subId, String puk, String pin) {
int [] resultArray = supplyPukReportResultForSubscriber(subId, puk, pin);
return (resultArray[0] == PhoneConstants.PIN_RESULT_SUCCESS) ? true : false;
}
- /** {@hide} */
- public int[] supplyPinReportResult(String pin) {
- return supplyPinReportResultForSubscriber(getDefaultSubscription(), pin);
- }
-
public int[] supplyPinReportResultForSubscriber(int subId, String pin) {
enforceModifyPermission();
@@ -1564,11 +1563,6 @@
}
}
- /** {@hide} */
- public int[] supplyPukReportResult(String puk, String pin) {
- return supplyPukReportResultForSubscriber(getDefaultSubscription(), puk, pin);
- }
-
public int[] supplyPukReportResultForSubscriber(int subId, String puk, String pin) {
enforceModifyPermission();
@@ -1701,15 +1695,29 @@
}
}
+ @Deprecated
@Override
public boolean isRadioOn(String callingPackage) {
- return isRadioOnForSubscriber(getDefaultSubscription(), callingPackage);
+ return isRadioOnWithFeature(callingPackage, null);
}
@Override
+ public boolean isRadioOnWithFeature(String callingPackage, String callingFeatureId) {
+ return isRadioOnForSubscriberWithFeature(getDefaultSubscription(), callingPackage,
+ callingFeatureId);
+ }
+
+ @Deprecated
+ @Override
public boolean isRadioOnForSubscriber(int subId, String callingPackage) {
+ return isRadioOnForSubscriberWithFeature(subId, callingPackage, null);
+ }
+
+ @Override
+ public boolean isRadioOnForSubscriberWithFeature(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "isRadioOnForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId, "isRadioOnForSubscriber")) {
return false;
}
@@ -1996,7 +2004,7 @@
}
@Override
- public Bundle getCellLocation(String callingPackage) {
+ public CellIdentity getCellLocation(String callingPackage, String callingFeatureId) {
mApp.getSystemService(AppOpsManager.class)
.checkPackage(Binder.getCallingUid(), callingPackage);
@@ -2004,6 +2012,7 @@
LocationAccessPolicy.checkLocationPermission(mApp,
new LocationAccessPolicy.LocationPermissionQuery.Builder()
.setCallingPackage(callingPackage)
+ .setCallingFeatureId(callingFeatureId)
.setCallingPid(Binder.getCallingPid())
.setCallingUid(Binder.getCallingUid())
.setMethod("getCellLocation")
@@ -2013,29 +2022,28 @@
case DENIED_HARD:
throw new SecurityException("Not allowed to access cell location");
case DENIED_SOFT:
- return new Bundle();
+ return (getDefaultPhone().getPhoneType() == PhoneConstants.PHONE_TYPE_CDMA)
+ ? new CellIdentityCdma() : new CellIdentityGsm();
}
WorkSource workSource = getWorkSource(Binder.getCallingUid());
final long identity = Binder.clearCallingIdentity();
try {
if (DBG_LOC) log("getCellLocation: is active user");
- Bundle data = new Bundle();
int subId = mSubscriptionController.getDefaultDataSubId();
- CellLocation cl = (CellLocation) sendRequest(CMD_GET_CELL_LOCATION, workSource, subId);
- cl.fillInNotifierBundle(data);
- return data;
+ return (CellIdentity) sendRequest(CMD_GET_CELL_LOCATION, workSource, subId);
} finally {
Binder.restoreCallingIdentity(identity);
}
}
@Override
- public String getNetworkCountryIsoForPhone(int phoneId, String callingPackage) {
+ public String getNetworkCountryIsoForPhone(int phoneId, String callingPackage,
+ String callingFeatureId) {
if (!TextUtils.isEmpty(callingPackage)) {
final int subId = mSubscriptionController.getSubIdUsingPhoneId(phoneId);
- if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getNetworkCountryIsoForPhone")) {
+ if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp, subId, callingPackage,
+ callingFeatureId, "getNetworkCountryIsoForPhone")) {
return "";
}
}
@@ -2052,7 +2060,8 @@
// Todo: fix this when we can get the actual cellular network info when the device
// is on IWLAN.
if (TelephonyManager.NETWORK_TYPE_IWLAN
- == getVoiceNetworkTypeForSubscriber(subId, mApp.getPackageName())) {
+ == getVoiceNetworkTypeForSubscriber(subId, mApp.getPackageName(),
+ null)) {
return "";
}
Phone phone = PhoneFactory.getPhone(phoneId);
@@ -2139,7 +2148,8 @@
@Override
@SuppressWarnings("unchecked")
- public List<NeighboringCellInfo> getNeighboringCellInfo(String callingPackage) {
+ public List<NeighboringCellInfo> getNeighboringCellInfo(String callingPackage,
+ String callingFeatureId) {
final int targetSdk = getTargetSdk(callingPackage);
if (targetSdk >= android.os.Build.VERSION_CODES.Q) {
throw new SecurityException(
@@ -2153,7 +2163,7 @@
if (DBG_LOC) log("getNeighboringCellInfo: is active user");
- List<CellInfo> info = getAllCellInfo(callingPackage);
+ List<CellInfo> info = getAllCellInfo(callingPackage, callingFeatureId);
if (info == null) return null;
List<NeighboringCellInfo> neighbors = new ArrayList<NeighboringCellInfo>();
@@ -2177,7 +2187,7 @@
}
@Override
- public List<CellInfo> getAllCellInfo(String callingPackage) {
+ public List<CellInfo> getAllCellInfo(String callingPackage, String callingFeatureId) {
mApp.getSystemService(AppOpsManager.class)
.checkPackage(Binder.getCallingUid(), callingPackage);
@@ -2185,6 +2195,7 @@
LocationAccessPolicy.checkLocationPermission(mApp,
new LocationAccessPolicy.LocationPermissionQuery.Builder()
.setCallingPackage(callingPackage)
+ .setCallingFeatureId(callingFeatureId)
.setCallingPid(Binder.getCallingPid())
.setCallingUid(Binder.getCallingUid())
.setMethod("getAllCellInfo")
@@ -2220,20 +2231,21 @@
}
@Override
- public void requestCellInfoUpdate(int subId, ICellInfoCallback cb, String callingPackage) {
- requestCellInfoUpdateInternal(
- subId, cb, callingPackage, getWorkSource(Binder.getCallingUid()));
+ public void requestCellInfoUpdate(int subId, ICellInfoCallback cb, String callingPackage,
+ String callingFeatureId) {
+ requestCellInfoUpdateInternal(subId, cb, callingPackage, callingFeatureId,
+ getWorkSource(Binder.getCallingUid()));
}
@Override
- public void requestCellInfoUpdateWithWorkSource(
- int subId, ICellInfoCallback cb, String callingPackage, WorkSource workSource) {
+ public void requestCellInfoUpdateWithWorkSource(int subId, ICellInfoCallback cb,
+ String callingPackage, String callingFeatureId, WorkSource workSource) {
enforceModifyPermission();
- requestCellInfoUpdateInternal(subId, cb, callingPackage, workSource);
+ requestCellInfoUpdateInternal(subId, cb, callingPackage, callingFeatureId, workSource);
}
- private void requestCellInfoUpdateInternal(
- int subId, ICellInfoCallback cb, String callingPackage, WorkSource workSource) {
+ private void requestCellInfoUpdateInternal(int subId, ICellInfoCallback cb,
+ String callingPackage, String callingFeatureId, WorkSource workSource) {
mApp.getSystemService(AppOpsManager.class)
.checkPackage(Binder.getCallingUid(), callingPackage);
@@ -2241,6 +2253,7 @@
LocationAccessPolicy.checkLocationPermission(mApp,
new LocationAccessPolicy.LocationPermissionQuery.Builder()
.setCallingPackage(callingPackage)
+ .setCallingFeatureId(callingFeatureId)
.setCallingPid(Binder.getCallingPid())
.setCallingUid(Binder.getCallingUid())
.setMethod("requestCellInfoUpdate")
@@ -2279,14 +2292,14 @@
}
@Override
- public String getImeiForSlot(int slotIndex, String callingPackage) {
+ public String getImeiForSlot(int slotIndex, String callingPackage, String callingFeatureId) {
Phone phone = PhoneFactory.getPhone(slotIndex);
if (phone == null) {
return null;
}
int subId = phone.getSubId();
if (!TelephonyPermissions.checkCallingOrSelfReadDeviceIdentifiers(mApp, subId,
- callingPackage, "getImeiForSlot")) {
+ callingPackage, callingFeatureId, "getImeiForSlot")) {
return null;
}
@@ -2310,7 +2323,7 @@
}
@Override
- public String getMeidForSlot(int slotIndex, String callingPackage) {
+ public String getMeidForSlot(int slotIndex, String callingPackage, String callingFeatureId) {
Phone phone = PhoneFactory.getPhone(slotIndex);
if (phone == null) {
return null;
@@ -2318,7 +2331,7 @@
int subId = phone.getSubId();
if (!TelephonyPermissions.checkCallingOrSelfReadDeviceIdentifiers(mApp, subId,
- callingPackage, "getMeidForSlot")) {
+ callingPackage, callingFeatureId, "getMeidForSlot")) {
return null;
}
@@ -2342,14 +2355,16 @@
}
@Override
- public String getDeviceSoftwareVersionForSlot(int slotIndex, String callingPackage) {
+ public String getDeviceSoftwareVersionForSlot(int slotIndex, String callingPackage,
+ String callingFeatureId) {
Phone phone = PhoneFactory.getPhone(slotIndex);
if (phone == null) {
return null;
}
int subId = phone.getSubId();
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getDeviceSoftwareVersionForSlot")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getDeviceSoftwareVersionForSlot")) {
return null;
}
@@ -2498,14 +2513,17 @@
* Returns the CDMA ERI icon index to display
*/
@Override
- public int getCdmaEriIconIndex(String callingPackage) {
- return getCdmaEriIconIndexForSubscriber(getDefaultSubscription(), callingPackage);
+ public int getCdmaEriIconIndex(String callingPackage, String callingFeatureId) {
+ return getCdmaEriIconIndexForSubscriber(getDefaultSubscription(), callingPackage,
+ callingFeatureId);
}
@Override
- public int getCdmaEriIconIndexForSubscriber(int subId, String callingPackage) {
+ public int getCdmaEriIconIndexForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getCdmaEriIconIndexForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getCdmaEriIconIndexForSubscriber")) {
return -1;
}
@@ -2528,14 +2546,17 @@
* 1 - FLASHING
*/
@Override
- public int getCdmaEriIconMode(String callingPackage) {
- return getCdmaEriIconModeForSubscriber(getDefaultSubscription(), callingPackage);
+ public int getCdmaEriIconMode(String callingPackage, String callingFeatureId) {
+ return getCdmaEriIconModeForSubscriber(getDefaultSubscription(), callingPackage,
+ callingFeatureId);
}
@Override
- public int getCdmaEriIconModeForSubscriber(int subId, String callingPackage) {
+ public int getCdmaEriIconModeForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getCdmaEriIconModeForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getCdmaEriIconModeForSubscriber")) {
return -1;
}
@@ -2556,14 +2577,17 @@
* Returns the CDMA ERI text,
*/
@Override
- public String getCdmaEriText(String callingPackage) {
- return getCdmaEriTextForSubscriber(getDefaultSubscription(), callingPackage);
+ public String getCdmaEriText(String callingPackage, String callingFeatureId) {
+ return getCdmaEriTextForSubscriber(getDefaultSubscription(), callingPackage,
+ callingFeatureId);
}
@Override
- public String getCdmaEriTextForSubscriber(int subId, String callingPackage) {
+ public String getCdmaEriTextForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getCdmaEriIconTextForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getCdmaEriIconTextForSubscriber")) {
return null;
}
@@ -2664,7 +2688,8 @@
*/
@Override
public boolean setVoiceMailNumber(int subId, String alphaTag, String number) {
- TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(subId, "setVoiceMailNumber");
+ TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(
+ mApp, subId, "setVoiceMailNumber");
final long identity = Binder.clearCallingIdentity();
try {
@@ -2698,10 +2723,12 @@
}
@Override
- public String getVisualVoicemailPackageName(String callingPackage, int subId) {
+ public String getVisualVoicemailPackageName(String callingPackage, String callingFeatureId,
+ int subId) {
mAppOps.checkPackage(Binder.getCallingUid(), callingPackage);
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getVisualVoicemailPackageName")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getVisualVoicemailPackageName")) {
return null;
}
@@ -2864,9 +2891,11 @@
* Returns the unread count of voicemails for a subId
*/
@Override
- public int getVoiceMessageCountForSubscriber(int subId, String callingPackage) {
+ public int getVoiceMessageCountForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getVoiceMessageCountForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getVoiceMessageCountForSubscriber")) {
return 0;
}
final long identity = Binder.clearCallingIdentity();
@@ -2909,7 +2938,7 @@
TelecomManager tm = defaultPhone.getContext().getSystemService(TelecomManager.class);
String defaultDialer = tm.getDefaultDialerPackage();
if (!TextUtils.equals(callingPackage, defaultDialer)) {
- TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(
+ TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(mApp,
getDefaultSubscription(), "sendDialerSpecialCode");
}
@@ -2923,11 +2952,18 @@
@Override
public int getNetworkSelectionMode(int subId) {
- if (!isActiveSubscription(subId)) {
- return TelephonyManager.NETWORK_SELECTION_MODE_UNKNOWN;
+ TelephonyPermissions
+ .enforeceCallingOrSelfReadPrecisePhoneStatePermissionOrCarrierPrivilege(
+ mApp, subId, "getNetworkSelectionMode");
+ final long identity = Binder.clearCallingIdentity();
+ try {
+ if (!isActiveSubscription(subId)) {
+ return TelephonyManager.NETWORK_SELECTION_MODE_UNKNOWN;
+ }
+ return (int) sendRequest(CMD_GET_NETWORK_SELECTION_MODE, null /* argument */, subId);
+ } finally {
+ Binder.restoreCallingIdentity(identity);
}
-
- return (int) sendRequest(CMD_GET_NETWORK_SELECTION_MODE, null /* argument */, subId);
}
@Override
@@ -2946,10 +2982,17 @@
return false;
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ * @param c The callback that will be used to send the result.
+ */
@Override
public void registerImsRegistrationCallback(int subId, IImsRegistrationCallback c)
throws RemoteException {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("registerImsRegistrationCallback");
+
if (!ImsManager.isImsSupportedOnDevice(mApp)) {
throw new ServiceSpecificException(ImsException.CODE_ERROR_UNSUPPORTED_OPERATION,
"IMS not available on device.");
@@ -2966,8 +3009,14 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ * @param c The callback that will be used to send the result.
+ */
@Override
public void unregisterImsRegistrationCallback(int subId, IImsRegistrationCallback c) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("unregisterImsRegistrationCallback");
if (!SubscriptionManager.isValidSubscriptionId(subId)) {
throw new IllegalArgumentException("Invalid Subscription ID: " + subId);
@@ -3024,6 +3073,7 @@
*/
@Override
public void getImsMmTelRegistrationTransportType(int subId, IIntegerConsumer consumer) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("getImsMmTelRegistrationTransportType");
if (!ImsManager.isImsSupportedOnDevice(mApp)) {
throw new ServiceSpecificException(ImsException.CODE_ERROR_UNSUPPORTED_OPERATION,
@@ -3055,9 +3105,15 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ * @param c The callback that will be used to send the result.
+ */
@Override
public void registerMmTelCapabilityCallback(int subId, IImsCapabilityCallback c)
throws RemoteException {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("registerMmTelCapabilityCallback");
if (!ImsManager.isImsSupportedOnDevice(mApp)) {
throw new ServiceSpecificException(ImsException.CODE_ERROR_UNSUPPORTED_OPERATION,
@@ -3075,8 +3131,14 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ * @param c The callback that will be used to send the result.
+ */
@Override
public void unregisterMmTelCapabilityCallback(int subId, IImsCapabilityCallback c) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("unregisterMmTelCapabilityCallback");
if (!SubscriptionManager.isValidSubscriptionId(subId)) {
throw new IllegalArgumentException("Invalid Subscription ID: " + subId);
@@ -3167,9 +3229,15 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ */
@Override
public boolean isAdvancedCallingSettingEnabled(int subId) {
- enforceReadPrivilegedPermission("enforceReadPrivilegedPermission");
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
+ enforceReadPrivilegedPermission("isAdvancedCallingSettingEnabled");
+
// TODO: Refactor to remove ImsManager dependence and query through ImsPhone directly.
final long token = Binder.clearCallingIdentity();
try {
@@ -3198,8 +3266,13 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ */
@Override
public boolean isVtSettingEnabled(int subId) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("isVtSettingEnabled");
final long identity = Binder.clearCallingIdentity();
try {
@@ -3227,8 +3300,13 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ */
@Override
public boolean isVoWiFiSettingEnabled(int subId) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("isVoWiFiSettingEnabled");
final long identity = Binder.clearCallingIdentity();
try {
@@ -3257,8 +3335,13 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ */
@Override
public boolean isVoWiFiRoamingSettingEnabled(int subId) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("isVoWiFiRoamingSettingEnabled");
final long identity = Binder.clearCallingIdentity();
try {
@@ -3304,8 +3387,13 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ */
@Override
public int getVoWiFiModeSetting(int subId) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("getVoWiFiModeSetting");
final long identity = Binder.clearCallingIdentity();
try {
@@ -3381,8 +3469,13 @@
}
}
+ /**
+ * Requires carrier privileges or READ_PRECISE_PHONE_STATE permission.
+ * @param subId The subscription to use to check the configuration.
+ */
@Override
public boolean isTtyOverVolteEnabled(int subId) {
+ //TODO: b/147498511 will add TelephonyPermissions#checkCallingOrSelfReadPrecisePhoneState
enforceReadPrivilegedPermission("isTtyOverVolteEnabled");
final long identity = Binder.clearCallingIdentity();
try {
@@ -3401,6 +3494,10 @@
enforceReadPrivilegedPermission("registerImsProvisioningChangedCallback");
final long identity = Binder.clearCallingIdentity();
try {
+ if (!isImsAvailableOnDevice()) {
+ throw new ServiceSpecificException(ImsException.CODE_ERROR_UNSUPPORTED_OPERATION,
+ "IMS not available on device.");
+ }
// TODO: Refactor to remove ImsManager dependence and query through ImsPhone directly.
ImsManager.getInstance(mApp, getSlotIndexOrException(subId))
.addProvisioningCallbackForSubscription(callback, subId);
@@ -3432,6 +3529,91 @@
}
}
+
+ private void checkModifyPhoneStatePermission(int subId, String message) {
+ TelephonyPermissions.enforceCallingOrSelfModifyPermissionOrCarrierPrivilege(mApp, subId,
+ message);
+ }
+
+ private boolean isImsProvisioningRequired(int subId, int capability,
+ boolean isMmtelCapability) {
+ Phone phone = getPhone(subId);
+ if (phone == null) {
+ loge("phone instance null for subid " + subId);
+ return false;
+ }
+ if (isMmtelCapability) {
+ if (!doesImsCapabilityRequireProvisioning(phone.getContext(), subId, capability)) {
+ return false;
+ }
+ } else {
+ if (!doesRcsCapabilityRequireProvisioning(phone.getContext(), subId, capability)) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+ @Override
+ public void setRcsProvisioningStatusForCapability(int subId, int capability,
+ boolean isProvisioned) {
+ checkModifyPhoneStatePermission(subId, "setRcsProvisioningStatusForCapability");
+
+ final long identity = Binder.clearCallingIdentity();
+ try {
+ // TODO: Refactor to remove ImsManager dependence and query through ImsPhone directly.
+ if (!isImsProvisioningRequired(subId, capability, false)) {
+ return;
+ }
+
+ // this capability requires provisioning, route to the correct API.
+ ImsManager ims = ImsManager.getInstance(mApp, getSlotIndex(subId));
+ switch (capability) {
+ case RcsFeature.RcsImsCapabilities.CAPABILITY_TYPE_OPTIONS_UCE:
+ case RcsFeature.RcsImsCapabilities.CAPABILITY_TYPE_PRESENCE_UCE:
+ ims.setEabProvisioned(isProvisioned);
+ break;
+ default: {
+ throw new IllegalArgumentException("Tried to set provisioning for "
+ + "rcs capability '" + capability + "', which does not require "
+ + "provisioning.");
+ }
+ }
+ } finally {
+ Binder.restoreCallingIdentity(identity);
+ }
+
+ }
+
+
+ @Override
+ public boolean getRcsProvisioningStatusForCapability(int subId, int capability) {
+ enforceReadPrivilegedPermission("getRcsProvisioningStatusForCapability");
+ final long identity = Binder.clearCallingIdentity();
+ try {
+ // TODO: Refactor to remove ImsManager dependence and query through ImsPhone directly.
+ if (!isImsProvisioningRequired(subId, capability, false)) {
+ return true;
+ }
+
+ ImsManager ims = ImsManager.getInstance(mApp, getSlotIndex(subId));
+ switch (capability) {
+ case RcsFeature.RcsImsCapabilities.CAPABILITY_TYPE_OPTIONS_UCE:
+ case RcsFeature.RcsImsCapabilities.CAPABILITY_TYPE_PRESENCE_UCE:
+ return ims.isEabProvisionedOnDevice();
+
+ default: {
+ throw new IllegalArgumentException("Tried to get rcs provisioning for "
+ + "capability '" + capability + "', which does not require "
+ + "provisioning.");
+ }
+ }
+
+ } finally {
+ Binder.restoreCallingIdentity(identity);
+ }
+ }
+
@Override
public void setImsProvisioningStatusForCapability(int subId, int capability, int tech,
boolean isProvisioned) {
@@ -3439,18 +3621,11 @@
&& tech != ImsRegistrationImplBase.REGISTRATION_TECH_LTE) {
throw new IllegalArgumentException("Registration technology '" + tech + "' is invalid");
}
- TelephonyPermissions.enforceCallingOrSelfModifyPermissionOrCarrierPrivilege(mApp, subId,
- "setProvisioningStatusForCapability");
+ checkModifyPhoneStatePermission(subId, "setImsProvisioningStatusForCapability");
final long identity = Binder.clearCallingIdentity();
try {
// TODO: Refactor to remove ImsManager dependence and query through ImsPhone directly.
- Phone phone = getPhone(subId);
- if (phone == null) {
- loge("setImsProvisioningStatusForCapability: phone instance null for subid "
- + subId);
- return;
- }
- if (!doesImsCapabilityRequireProvisioning(phone.getContext(), subId, capability)) {
+ if (!isImsProvisioningRequired(subId, capability, true)) {
return;
}
@@ -3488,8 +3663,9 @@
break;
}
default: {
- throw new IllegalArgumentException("Tried to set provisioning for capability '"
- + capability + "', which does not require provisioning.");
+ throw new IllegalArgumentException("Tried to set provisioning for "
+ + "MmTel capability '" + capability + "', which does not require "
+ + "provisioning. ");
}
}
@@ -3508,16 +3684,7 @@
final long identity = Binder.clearCallingIdentity();
try {
// TODO: Refactor to remove ImsManager dependence and query through ImsPhone directly.
- Phone phone = getPhone(subId);
- if (phone == null) {
- loge("getImsProvisioningStatusForCapability: phone instance null for subid "
- + subId);
- // We will fail with "true" as the provisioning status because this is the default
- // if we do not require provisioning.
- return true;
- }
-
- if (!doesImsCapabilityRequireProvisioning(phone.getContext(), subId, capability)) {
+ if (!isImsProvisioningRequired(subId, capability, true)) {
return true;
}
@@ -3543,8 +3710,9 @@
return isMmTelCapabilityProvisionedInCache(subId, capability, tech);
}
default: {
- throw new IllegalArgumentException("Tried to get provisioning for capability '"
- + capability + "', which does not require provisioning.");
+ throw new IllegalArgumentException(
+ "Tried to get provisioning for MmTel capability '" + capability
+ + "', which does not require provisioning.");
}
}
@@ -3653,6 +3821,29 @@
return false;
}
+ private boolean doesRcsCapabilityRequireProvisioning(Context context, int subId,
+ int capability) {
+ CarrierConfigManager configManager = new CarrierConfigManager(context);
+ PersistableBundle c = configManager.getConfigForSubId(subId);
+
+ boolean requireRcsProvisioning = c.getBoolean(
+ CarrierConfigManager.KEY_CARRIER_RCS_PROVISIONING_REQUIRED_BOOL, false);
+
+ // First check to make sure that the capability requires provisioning.
+ switch (capability) {
+ case RcsFeature.RcsImsCapabilities.CAPABILITY_TYPE_PRESENCE_UCE:
+ // intentional fallthrough
+ case RcsFeature.RcsImsCapabilities.CAPABILITY_TYPE_OPTIONS_UCE: {
+ if (requireRcsProvisioning) {
+ // OPTION or PRESENCE requires provisioning
+ return true;
+ }
+ break;
+ }
+ }
+ return false;
+ }
+
@Override
public int getImsProvisioningInt(int subId, int key) {
if (!SubscriptionManager.isValidSubscriptionId(subId)) {
@@ -3776,13 +3967,15 @@
* Returns the data network type for a subId; does not throw SecurityException.
*/
@Override
- public int getNetworkTypeForSubscriber(int subId, String callingPackage) {
+ public int getNetworkTypeForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
final int targetSdk = getTargetSdk(callingPackage);
if (targetSdk > android.os.Build.VERSION_CODES.Q) {
- return getDataNetworkTypeForSubscriber(subId, callingPackage);
+ return getDataNetworkTypeForSubscriber(subId, callingPackage, callingFeatureId);
} else if (targetSdk == android.os.Build.VERSION_CODES.Q
&& !TelephonyPermissions.checkCallingOrSelfReadPhoneStateNoThrow(
- mApp, subId, callingPackage, "getNetworkTypeForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getNetworkTypeForSubscriber")) {
return TelephonyManager.NETWORK_TYPE_UNKNOWN;
}
@@ -3803,17 +3996,20 @@
* Returns the data network type
*/
@Override
- public int getDataNetworkType(String callingPackage) {
- return getDataNetworkTypeForSubscriber(getDefaultSubscription(), callingPackage);
+ public int getDataNetworkType(String callingPackage, String callingFeatureId) {
+ return getDataNetworkTypeForSubscriber(getDefaultSubscription(), callingPackage,
+ callingFeatureId);
}
/**
* Returns the data network type for a subId
*/
@Override
- public int getDataNetworkTypeForSubscriber(int subId, String callingPackage) {
+ public int getDataNetworkTypeForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getDataNetworkTypeForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getDataNetworkTypeForSubscriber")) {
return TelephonyManager.NETWORK_TYPE_UNKNOWN;
}
@@ -3834,9 +4030,11 @@
* Returns the Voice network type for a subId
*/
@Override
- public int getVoiceNetworkTypeForSubscriber(int subId, String callingPackage) {
+ public int getVoiceNetworkTypeForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getDataNetworkTypeForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getDataNetworkTypeForSubscriber")) {
return TelephonyManager.NETWORK_TYPE_UNKNOWN;
}
@@ -3890,14 +4088,17 @@
* or {@link Phone#LTE_ON_CDMA_TRUE}
*/
@Override
- public int getLteOnCdmaMode(String callingPackage) {
- return getLteOnCdmaModeForSubscriber(getDefaultSubscription(), callingPackage);
+ public int getLteOnCdmaMode(String callingPackage, String callingFeatureId) {
+ return getLteOnCdmaModeForSubscriber(getDefaultSubscription(), callingPackage,
+ callingFeatureId);
}
@Override
- public int getLteOnCdmaModeForSubscriber(int subId, String callingPackage) {
+ public int getLteOnCdmaModeForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getLteOnCdmaModeForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getLteOnCdmaModeForSubscriber")) {
return PhoneConstants.LTE_ON_CDMA_UNKNOWN;
}
@@ -4221,9 +4422,10 @@
* Get the forbidden PLMN List from the given app type (ex APPTYPE_USIM)
* on a particular subscription
*/
- public String[] getForbiddenPlmns(int subId, int appType, String callingPackage) {
+ public String[] getForbiddenPlmns(int subId, int appType, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getForbiddenPlmns")) {
+ mApp, subId, callingPackage, callingFeatureId, "getForbiddenPlmns")) {
return null;
}
@@ -4255,12 +4457,13 @@
* @param appType the uicc app type, must be USIM or SIM.
* @param fplmns the Forbiden plmns list that needed to be written to the SIM.
* @param callingPackage the op Package name.
+ * @param callingFeatureId the feature in the package.
* @return number of fplmns that is successfully written to the SIM.
*/
- public int setForbiddenPlmns(
- int subId, int appType, List<String> fplmns, String callingPackage) {
- if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "setForbiddenPlmns")) {
+ public int setForbiddenPlmns(int subId, int appType, List<String> fplmns, String callingPackage,
+ String callingFeatureId) {
+ if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp, subId, callingPackage,
+ callingFeatureId, "setForbiddenPlmns")) {
if (DBG) logv("no permissions for setForbiddenplmns");
throw new IllegalStateException("No Permissions for setForbiddenPlmns");
}
@@ -4436,10 +4639,11 @@
return false;
}
- public String[] getPcscfAddress(String apnType, String callingPackage) {
+ public String[] getPcscfAddress(String apnType, String callingPackage,
+ String callingFeatureId) {
final Phone defaultPhone = getDefaultPhone();
- if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, defaultPhone.getSubId(), callingPackage, "getPcscfAddress")) {
+ if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp, defaultPhone.getSubId(),
+ callingPackage, callingFeatureId, "getPcscfAddress")) {
return new String[0];
}
@@ -4452,6 +4656,27 @@
}
/**
+ * Toggle IMS disable and enable for the framework to reset it. See {@link #enableIms(int)} and
+ * {@link #disableIms(int)}.
+ * @param slotIndex device slot.
+ */
+ public void resetIms(int slotIndex) {
+ enforceModifyPermission();
+
+ final long identity = Binder.clearCallingIdentity();
+ try {
+ if (mImsResolver == null) {
+ // may happen if the does not support IMS.
+ return;
+ }
+ mImsResolver.disableIms(slotIndex);
+ mImsResolver.enableIms(slotIndex);
+ } finally {
+ Binder.restoreCallingIdentity(identity);
+ }
+ }
+
+ /**
* Enables IMS for the framework. This will trigger IMS registration and ImsFeature capability
* status updates, if not already enabled.
*/
@@ -4690,12 +4915,11 @@
TelephonyPermissions.enforceCallingOrSelfModifyPermissionOrCarrierPrivilege(
mApp, subId, "setNetworkSelectionModeAutomatic");
- if (!isActiveSubscription(subId)) {
- return;
- }
-
final long identity = Binder.clearCallingIdentity();
try {
+ if (!isActiveSubscription(subId)) {
+ return;
+ }
if (DBG) log("setNetworkSelectionModeAutomatic: subId " + subId);
sendRequest(CMD_SET_NETWORK_SELECTION_MODE_AUTOMATIC, null, subId);
} finally {
@@ -4742,13 +4966,15 @@
* Scans for available networks.
*/
@Override
- public CellNetworkScanResult getCellNetworkScanResults(int subId, String callingPackage) {
+ public CellNetworkScanResult getCellNetworkScanResults(int subId, String callingPackage,
+ String callingFeatureId) {
TelephonyPermissions.enforceCallingOrSelfModifyPermissionOrCarrierPrivilege(
mApp, subId, "getCellNetworkScanResults");
LocationAccessPolicy.LocationPermissionResult locationResult =
LocationAccessPolicy.checkLocationPermission(mApp,
new LocationAccessPolicy.LocationPermissionQuery.Builder()
.setCallingPackage(callingPackage)
+ .setCallingFeatureId(callingFeatureId)
.setCallingPid(Binder.getCallingPid())
.setCallingUid(Binder.getCallingUid())
.setMethod("getCellNetworkScanResults")
@@ -4782,13 +5008,14 @@
*/
@Override
public int requestNetworkScan(int subId, NetworkScanRequest request, Messenger messenger,
- IBinder binder, String callingPackage) {
+ IBinder binder, String callingPackage, String callingFeatureId) {
TelephonyPermissions.enforceCallingOrSelfModifyPermissionOrCarrierPrivilege(
mApp, subId, "requestNetworkScan");
LocationAccessPolicy.LocationPermissionResult locationResult =
LocationAccessPolicy.checkLocationPermission(mApp,
new LocationAccessPolicy.LocationPermissionQuery.Builder()
.setCallingPackage(callingPackage)
+ .setCallingFeatureId(callingFeatureId)
.setCallingPid(Binder.getCallingPid())
.setCallingUid(Binder.getCallingUid())
.setMethod("requestNetworkScan")
@@ -4869,10 +5096,10 @@
* @return the preferred network type, defined in RILConstants.java.
*/
@Override
- public int getCalculatedPreferredNetworkType(String callingPackage) {
+ public int getCalculatedPreferredNetworkType(String callingPackage, String callingFeatureId) {
final Phone defaultPhone = getDefaultPhone();
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp, defaultPhone.getSubId(),
- callingPackage, "getCalculatedPreferredNetworkType")) {
+ callingPackage, callingFeatureId, "getCalculatedPreferredNetworkType")) {
return RILConstants.PREFERRED_NETWORK_MODE;
}
@@ -4923,21 +5150,81 @@
final long identity = Binder.clearCallingIdentity();
try {
- if (DBG) log("setPreferredNetworkType: subId " + subId + " type " + networkType);
- Boolean success = (Boolean) sendRequest(
- CMD_SET_PREFERRED_NETWORK_TYPE, networkType, subId);
- if (DBG) log("setPreferredNetworkType: " + (success ? "ok" : "fail"));
- if (success) {
- Settings.Global.putInt(mApp.getContentResolver(),
- Settings.Global.PREFERRED_NETWORK_MODE + subId, networkType);
- }
- return success;
+ Settings.Global.putInt(mApp.getContentResolver(),
+ Settings.Global.PREFERRED_NETWORK_MODE + subId, networkType);
+ return setPreferredNetworkTypesInternal(subId);
} finally {
Binder.restoreCallingIdentity(identity);
}
}
/**
+ * Get the allowed network types that store in the telephony provider.
+ *
+ * @param subId the id of the subscription.
+ * @return allowedNetworkTypes the allowed network types.
+ */
+ @Override
+ public long getAllowedNetworkTypes(int subId) {
+ TelephonyPermissions
+ .enforeceCallingOrSelfReadPrivilegedPhoneStatePermissionOrCarrierPrivilege(
+ mApp, subId, "getAllowedNetworkTypes");
+
+ final long identity = Binder.clearCallingIdentity();
+ try {
+ return SubscriptionManager.getLongSubscriptionProperty(
+ subId, SubscriptionManager.ALLOWED_NETWORK_TYPES, -1, mApp);
+ } finally {
+ Binder.restoreCallingIdentity(identity);
+ }
+ }
+
+ /**
+ * Set the allowed network types.
+ *
+ * @param subId the id of the subscription.
+ * @param allowedNetworkTypes the allowed network types.
+ * @return true on success; false on any failure.
+ */
+ @Override
+ public boolean setAllowedNetworkTypes(int subId, long allowedNetworkTypes) {
+ TelephonyPermissions.enforceCallingOrSelfModifyPermissionOrCarrierPrivilege(
+ mApp, subId, "setAllowedNetworkTypes");
+ final long identity = Binder.clearCallingIdentity();
+ try {
+ SubscriptionManager.setSubscriptionProperty(subId,
+ SubscriptionManager.ALLOWED_NETWORK_TYPES,
+ String.valueOf(allowedNetworkTypes));
+ return setPreferredNetworkTypesInternal(subId);
+ } finally {
+ Binder.restoreCallingIdentity(identity);
+ }
+ }
+
+ private boolean setPreferredNetworkTypesInternal(int subId) {
+ long networkTypeBitMask = RadioAccessFamily.getRafFromNetworkType(
+ Settings.Global.getInt(mApp.getContentResolver(),
+ Settings.Global.PREFERRED_NETWORK_MODE + subId,
+ RILConstants.PREFERRED_NETWORK_MODE));
+ long allowedNetworkTypes = SubscriptionManager.getLongSubscriptionProperty(
+ subId, SubscriptionManager.ALLOWED_NETWORK_TYPES, -1, mApp);
+ int networkMode = RadioAccessFamily.getNetworkTypeFromRaf(
+ (int) (networkTypeBitMask & allowedNetworkTypes));
+
+ if (DBG) {
+ log("setPreferredNetworkTypesInternal: subId " + subId
+ + " networkTypes " + networkTypeBitMask
+ + " allowedNetworkTypes " + allowedNetworkTypes
+ + " networkMode " + networkMode);
+ }
+
+ Boolean success = (Boolean) sendRequest(
+ CMD_SET_PREFERRED_NETWORK_TYPE, networkMode, subId);
+ if (DBG) log("setPreferredNetworkTypesInternal: " + (success ? "ok" : "fail"));
+ return success;
+ }
+
+ /**
* Check whether DUN APN is required for tethering with subId.
*
* @param subId the id of the subscription to require tethering.
@@ -5144,6 +5431,7 @@
@Override
public int getCarrierPrivilegeStatusForUid(int subId, int uid) {
+ enforceReadPrivilegedPermission("getCarrierPrivilegeStatusForUid");
final Phone phone = getPhone(subId);
if (phone == null) {
loge("getCarrierPrivilegeStatusForUid: Invalid subId");
@@ -5156,8 +5444,8 @@
return TelephonyManager.CARRIER_PRIVILEGE_STATUS_RULES_NOT_LOADED;
}
return getCarrierPrivilegeStatusFromCarrierConfigRules(
- profile.getCarrierPrivilegeStatusForUid(
- phone.getContext().getPackageManager(), uid), phone);
+ profile.getCarrierPrivilegeStatusForUid(
+ phone.getContext().getPackageManager(), uid), phone);
}
@Override
@@ -5279,7 +5567,7 @@
@Override
public boolean setLine1NumberForDisplayForSubscriber(int subId, String alphaTag,
String number) {
- TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(
+ TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(mApp,
subId, "setLine1NumberForDisplayForSubscriber");
final long identity = Binder.clearCallingIdentity();
@@ -5329,10 +5617,11 @@
}
@Override
- public String getLine1NumberForDisplay(int subId, String callingPackage) {
+ public String getLine1NumberForDisplay(int subId, String callingPackage,
+ String callingFeatureId) {
// This is open to apps with WRITE_SMS.
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneNumber(
- mApp, subId, callingPackage, "getLine1NumberForDisplay")) {
+ mApp, subId, callingPackage, callingFeatureId, "getLine1NumberForDisplay")) {
if (DBG_MERGE) log("getLine1NumberForDisplay returning null due to permission");
return null;
}
@@ -5356,9 +5645,10 @@
}
@Override
- public String getLine1AlphaTagForDisplay(int subId, String callingPackage) {
+ public String getLine1AlphaTagForDisplay(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getLine1AlphaTagForDisplay")) {
+ mApp, subId, callingPackage, callingFeatureId, "getLine1AlphaTagForDisplay")) {
return null;
}
@@ -5376,12 +5666,13 @@
}
@Override
- public String[] getMergedSubscriberIds(int subId, String callingPackage) {
+ public String[] getMergedSubscriberIds(int subId, String callingPackage,
+ String callingFeatureId) {
// This API isn't public, so no need to provide a valid subscription ID - we're not worried
// about carrier-privileged callers not having access.
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
mApp, SubscriptionManager.INVALID_SUBSCRIPTION_ID, callingPackage,
- "getMergedSubscriberIds")) {
+ callingFeatureId, "getMergedSubscriberIds")) {
return null;
}
@@ -5486,7 +5777,8 @@
// Get all subscriberIds from the group.
final List<String> mergedSubscriberIds = new ArrayList<>();
final List<SubscriptionInfo> groupInfos = SubscriptionController.getInstance()
- .getSubscriptionsInGroup(groupUuid, mApp.getOpPackageName());
+ .getSubscriptionsInGroup(groupUuid, mApp.getOpPackageName(),
+ null);
for (SubscriptionInfo subInfo : groupInfos) {
subscriberId = telephonyManager.getSubscriberId(subInfo.getSubscriptionId());
if (subscriberId != null) {
@@ -5503,7 +5795,7 @@
@Override
public boolean setOperatorBrandOverride(int subId, String brand) {
- TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(
+ TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(mApp,
subId, "setOperatorBrandOverride");
final long identity = Binder.clearCallingIdentity();
@@ -5519,7 +5811,8 @@
public boolean setRoamingOverride(int subId, List<String> gsmRoamingList,
List<String> gsmNonRoamingList, List<String> cdmaRoamingList,
List<String> cdmaNonRoamingList) {
- TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(subId, "setRoamingOverride");
+ TelephonyPermissions.enforceCallingOrSelfCarrierPrivilege(
+ mApp, subId, "setRoamingOverride");
final long identity = Binder.clearCallingIdentity();
try {
@@ -5610,10 +5903,10 @@
}
@Override
- public boolean isVideoCallingEnabled(String callingPackage) {
+ public boolean isVideoCallingEnabled(String callingPackage, String callingFeatureId) {
final Phone defaultPhone = getDefaultPhone();
- if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, defaultPhone.getSubId(), callingPackage, "isVideoCallingEnabled")) {
+ if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp, defaultPhone.getSubId(),
+ callingPackage, callingFeatureId, "isVideoCallingEnabled")) {
return false;
}
@@ -5634,9 +5927,11 @@
}
@Override
- public boolean canChangeDtmfToneLength(int subId, String callingPackage) {
+ public boolean canChangeDtmfToneLength(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "isVideoCallingEnabled")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "isVideoCallingEnabled")) {
return false;
}
@@ -5652,9 +5947,9 @@
}
@Override
- public boolean isWorldPhone(int subId, String callingPackage) {
+ public boolean isWorldPhone(int subId, String callingPackage, String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "isVideoCallingEnabled")) {
+ mApp, subId, callingPackage, callingFeatureId, "isVideoCallingEnabled")) {
return false;
}
@@ -5718,12 +6013,23 @@
public boolean isRttEnabled(int subscriptionId) {
final long identity = Binder.clearCallingIdentity();
try {
- return isRttSupported(subscriptionId);
+ boolean isRttSupported = isRttSupported(subscriptionId);
+ boolean isUserRttSettingOn = Settings.Secure.getInt(
+ mApp.getContentResolver(), Settings.Secure.RTT_CALLING_MODE, 0) != 0;
+ boolean shouldIgnoreUserRttSetting = mApp.getCarrierConfigForSubId(subscriptionId)
+ .getBoolean(CarrierConfigManager.KEY_IGNORE_RTT_MODE_SETTING_BOOL);
+ return isRttSupported && (isUserRttSettingOn || shouldIgnoreUserRttSetting);
} finally {
Binder.restoreCallingIdentity(identity);
}
}
+ @Deprecated
+ @Override
+ public String getDeviceId(String callingPackage) {
+ return getDeviceIdWithFeature(callingPackage, null);
+ }
+
/**
* Returns the unique device ID of phone, for example, the IMEI for
* GSM and the MEID for CDMA phones. Return null if device ID is not available.
@@ -5732,14 +6038,14 @@
* {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
*/
@Override
- public String getDeviceId(String callingPackage) {
+ public String getDeviceIdWithFeature(String callingPackage, String callingFeatureId) {
final Phone phone = PhoneFactory.getPhone(0);
if (phone == null) {
return null;
}
int subId = phone.getSubId();
if (!TelephonyPermissions.checkCallingOrSelfReadDeviceIdentifiers(mApp, subId,
- callingPackage, "getDeviceId")) {
+ callingPackage, callingFeatureId, "getDeviceId")) {
return null;
}
@@ -5778,9 +6084,9 @@
@Override
public int getSubIdForPhoneAccountHandle(
- PhoneAccountHandle phoneAccountHandle, String callingPackage) {
+ PhoneAccountHandle phoneAccountHandle, String callingPackage, String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp, getDefaultSubscription(),
- callingPackage, "getSubIdForPhoneAccountHandle")) {
+ callingPackage, callingFeatureId, "getSubIdForPhoneAccountHandle")) {
throw new SecurityException("Requires READ_PHONE_STATE permission.");
}
final long identity = Binder.clearCallingIdentity();
@@ -5914,7 +6220,7 @@
final long identity = Binder.clearCallingIdentity();
try {
final SubscriptionInfo info = mSubscriptionController.getActiveSubscriptionInfo(subId,
- phone.getContext().getOpPackageName());
+ phone.getContext().getOpPackageName(), null);
if (info == null) {
log("getSimLocaleForSubscriber, inactive subId: " + subId);
return null;
@@ -5952,14 +6258,16 @@
}
private List<SubscriptionInfo> getAllSubscriptionInfoList() {
- return mSubscriptionController.getAllSubInfoList(mApp.getOpPackageName());
+ return mSubscriptionController.getAllSubInfoList(mApp.getOpPackageName(),
+ null);
}
/**
* NOTE: this method assumes permission checks are done and caller identity has been cleared.
*/
private List<SubscriptionInfo> getActiveSubscriptionInfoListPrivileged() {
- return mSubscriptionController.getActiveSubscriptionInfoList(mApp.getOpPackageName());
+ return mSubscriptionController.getActiveSubscriptionInfoList(mApp.getOpPackageName(),
+ null);
}
private final ModemActivityInfo mLastModemActivityInfo =
@@ -6042,9 +6350,10 @@
* Returns the service state information on specified subscription.
*/
@Override
- public ServiceState getServiceStateForSubscriber(int subId, String callingPackage) {
+ public ServiceState getServiceStateForSubscriber(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getServiceStateForSubscriber")) {
+ mApp, subId, callingPackage, callingFeatureId, "getServiceStateForSubscriber")) {
return null;
}
@@ -6052,6 +6361,7 @@
LocationAccessPolicy.checkLocationPermission(mApp,
new LocationAccessPolicy.LocationPermissionQuery.Builder()
.setCallingPackage(callingPackage)
+ .setCallingFeatureId(callingFeatureId)
.setCallingPid(Binder.getCallingPid())
.setCallingUid(Binder.getCallingUid())
.setMethod("getServiceStateForSubscriber")
@@ -6063,6 +6373,7 @@
LocationAccessPolicy.checkLocationPermission(mApp,
new LocationAccessPolicy.LocationPermissionQuery.Builder()
.setCallingPackage(callingPackage)
+ .setCallingFeatureId(callingFeatureId)
.setCallingPid(Binder.getCallingPid())
.setCallingUid(Binder.getCallingUid())
.setMethod("getServiceStateForSubscriber")
@@ -6087,8 +6398,8 @@
// Scrub out the location info in ServiceState depending on what level of access
// the caller has.
if (hasFinePermission) return ss;
- if (hasCoarsePermission) return ss.sanitizeLocationInfo(false);
- return ss.sanitizeLocationInfo(true);
+ if (hasCoarsePermission) return ss.createLocationInfoSanitizedCopy(false);
+ return ss.createLocationInfoSanitizedCopy(true);
} finally {
Binder.restoreCallingIdentity(identity);
}
@@ -6592,9 +6903,10 @@
* @hide
*/
@Override
- public List<ClientRequestStats> getClientRequestStats(String callingPackage, int subId) {
+ public List<ClientRequestStats> getClientRequestStats(String callingPackage,
+ String callingFeatureId, int subId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getClientRequestStats")) {
+ mApp, subId, callingPackage, callingFeatureId, "getClientRequestStats")) {
return null;
}
Phone phone = getPhone(subId);
@@ -6705,14 +7017,15 @@
* Get the current modem radio state for the given slot.
* @param slotIndex slot index.
* @param callingPackage the name of the package making the call.
+ * @param callingFeatureId The feature in the package.
* @return the current radio power state from the modem
*/
@Override
- public int getRadioPowerState(int slotIndex, String callingPackage) {
+ public int getRadioPowerState(int slotIndex, String callingPackage, String callingFeatureId) {
Phone phone = PhoneFactory.getPhone(slotIndex);
if (phone != null) {
- if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, phone.getSubId(), callingPackage, "getRadioPowerState")) {
+ if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp, phone.getSubId(),
+ callingPackage, callingFeatureId, "getRadioPowerState")) {
return TelephonyManager.RADIO_POWER_UNAVAILABLE;
}
@@ -7062,9 +7375,11 @@
}
@Override
- public int getNumberOfModemsWithSimultaneousDataConnections(int subId, String callingPackage) {
+ public int getNumberOfModemsWithSimultaneousDataConnections(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "getNumberOfModemsWithSimultaneousDataConnections")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "getNumberOfModemsWithSimultaneousDataConnections")) {
return -1;
}
@@ -7117,9 +7432,10 @@
@Override
public Map<Integer, List<EmergencyNumber>> getEmergencyNumberList(
- String callingPackage) {
+ String callingPackage, String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, getDefaultSubscription(), callingPackage, "getEmergencyNumberList")) {
+ mApp, getDefaultSubscription(), callingPackage, callingFeatureId,
+ "getEmergencyNumberList")) {
throw new SecurityException("Requires READ_PHONE_STATE permission.");
}
final long identity = Binder.clearCallingIdentity();
@@ -7305,12 +7621,14 @@
* Whether a modem stack is enabled or not.
*/
@Override
- public boolean isModemEnabledForSlot(int slotIndex, String callingPackage) {
+ public boolean isModemEnabledForSlot(int slotIndex, String callingPackage,
+ String callingFeatureId) {
Phone phone = PhoneFactory.getPhone(slotIndex);
if (phone == null) return false;
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, phone.getSubId(), callingPackage, "isModemEnabledForSlot")) {
+ mApp, phone.getSubId(), callingPackage, callingFeatureId,
+ "isModemEnabledForSlot")) {
throw new SecurityException("Requires READ_PHONE_STATE permission.");
}
@@ -7342,9 +7660,10 @@
@Override
@TelephonyManager.IsMultiSimSupportedResult
- public int isMultiSimSupported(String callingPackage) {
+ public int isMultiSimSupported(String callingPackage, String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(mApp,
- getDefaultPhone().getSubId(), callingPackage, "isMultiSimSupported")) {
+ getDefaultPhone().getSubId(), callingPackage, callingFeatureId,
+ "isMultiSimSupported")) {
return TelephonyManager.MULTISIM_NOT_SUPPORTED_BY_HARDWARE;
}
@@ -7445,9 +7764,11 @@
* Return value defaults to true.
*/
@Override
- public boolean doesSwitchMultiSimConfigTriggerReboot(int subId, String callingPackage) {
+ public boolean doesSwitchMultiSimConfigTriggerReboot(int subId, String callingPackage,
+ String callingFeatureId) {
if (!TelephonyPermissions.checkCallingOrSelfReadPhoneState(
- mApp, subId, callingPackage, "doesSwitchMultiSimConfigTriggerReboot")) {
+ mApp, subId, callingPackage, callingFeatureId,
+ "doesSwitchMultiSimConfigTriggerReboot")) {
return false;
}
final long identity = Binder.clearCallingIdentity();
@@ -7546,6 +7867,17 @@
}
@Override
+ public boolean isMvnoMatched(int subId, int mvnoType, @NonNull String mvnoMatchData) {
+ IccRecords iccRecords = UiccController.getInstance().getIccRecords(
+ SubscriptionManager.getPhoneId(subId), UiccController.APP_FAM_3GPP);
+ if (iccRecords == null) {
+ Log.d(LOG_TAG, "isMvnoMatched# IccRecords is null");
+ return false;
+ }
+ return ApnSettingUtils.mvnoMatches(iccRecords, mvnoType, mvnoMatchData);
+ }
+
+ @Override
public void enqueueSmsPickResult(String callingPackage, IIntegerConsumer pendingSubIdResult) {
SmsPermissions permissions = new SmsPermissions(getDefaultPhone(), mApp,
(AppOpsManager) mApp.getSystemService(Context.APP_OPS_SERVICE));
@@ -7645,4 +7977,28 @@
Binder.restoreCallingIdentity(identity);
}
}
+
+ /**
+ * Notify that an RCS autoconfiguration XML file has been received for provisioning.
+ *
+ * @param config The XML file to be read. ASCII/UTF8 encoded text if not compressed.
+ * @param isCompressed The XML file is compressed in gzip format and must be decompressed
+ * before being read.
+ */
+ @Override
+ public void notifyRcsAutoConfigurationReceived(int subId, @NonNull byte[] config, boolean
+ isCompressed) {
+ TelephonyPermissions.enforceCallingOrSelfModifyPermissionOrCarrierPrivilege(
+ mApp, subId, "notifyRcsAutoConfigurationReceived");
+ try {
+ IImsConfig configBinder = getImsConfig(getSlotIndex(subId), ImsFeature.FEATURE_RCS);
+ if (configBinder == null) {
+ Rlog.e(LOG_TAG, "null result for getImsConfig");
+ } else {
+ configBinder.notifyRcsAutoConfigurationReceived(config, isCompressed);
+ }
+ } catch (RemoteException e) {
+ Rlog.e(LOG_TAG, "fail to getImsConfig " + e.getMessage());
+ }
+ }
}
diff --git a/src/com/android/phone/PhoneUtils.java b/src/com/android/phone/PhoneUtils.java
index c865f14..20a818e 100644
--- a/src/com/android/phone/PhoneUtils.java
+++ b/src/com/android/phone/PhoneUtils.java
@@ -31,7 +31,7 @@
import android.telecom.VideoProfile;
import android.telephony.CarrierConfigManager;
import android.telephony.PhoneNumberUtils;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import android.telephony.SubscriptionManager;
import android.text.TextUtils;
import android.util.Log;
diff --git a/src/com/android/phone/ServiceStateProvider.java b/src/com/android/phone/ServiceStateProvider.java
new file mode 100644
index 0000000..a7d27d5
--- /dev/null
+++ b/src/com/android/phone/ServiceStateProvider.java
@@ -0,0 +1,566 @@
+/*
+ * Copyright (C) 2019 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.
+ */
+
+package com.android.phone;
+
+import static android.provider.Telephony.ServiceStateTable;
+import static android.provider.Telephony.ServiceStateTable.CONTENT_URI;
+import static android.provider.Telephony.ServiceStateTable.IS_MANUAL_NETWORK_SELECTION;
+import static android.provider.Telephony.ServiceStateTable.VOICE_REG_STATE;
+import static android.provider.Telephony.ServiceStateTable.getUriForSubscriptionId;
+import static android.provider.Telephony.ServiceStateTable.getUriForSubscriptionIdAndField;
+
+import android.content.ContentProvider;
+import android.content.ContentValues;
+import android.content.Context;
+import android.database.Cursor;
+import android.database.MatrixCursor;
+import android.database.MatrixCursor.RowBuilder;
+import android.net.Uri;
+import android.os.Parcel;
+import android.telephony.ServiceState;
+import android.telephony.SubscriptionManager;
+import android.util.Log;
+
+import com.android.internal.annotations.VisibleForTesting;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Objects;
+
+/**
+ * The class to provide base facility to access ServiceState related content,
+ * which is stored in a SQLite database.
+ */
+public class ServiceStateProvider extends ContentProvider {
+ private static final String TAG = "ServiceStateProvider";
+
+ public static final String AUTHORITY = ServiceStateTable.AUTHORITY;
+ public static final Uri AUTHORITY_URI = Uri.parse("content://" + AUTHORITY);
+
+ /**
+ * The current service state.
+ *
+ * This is the entire {@link ServiceState} object in byte array.
+ *
+ * @hide
+ */
+ public static final String SERVICE_STATE = "service_state";
+
+ /**
+ * An integer value indicating the current data service state.
+ * <p>
+ * Valid values: {@link ServiceState#STATE_IN_SERVICE},
+ * {@link ServiceState#STATE_OUT_OF_SERVICE}, {@link ServiceState#STATE_EMERGENCY_ONLY},
+ * {@link ServiceState#STATE_POWER_OFF}.
+ * <p>
+ * This is the same as {@link ServiceState#getDataRegState()}.
+ * @hide
+ */
+ public static final String DATA_REG_STATE = "data_reg_state";
+
+ /**
+ * An integer value indicating the current voice roaming type.
+ * <p>
+ * This is the same as {@link ServiceState#getVoiceRoamingType()}.
+ * @hide
+ */
+ public static final String VOICE_ROAMING_TYPE = "voice_roaming_type";
+
+ /**
+ * An integer value indicating the current data roaming type.
+ * <p>
+ * This is the same as {@link ServiceState#getDataRoamingType()}.
+ * @hide
+ */
+ public static final String DATA_ROAMING_TYPE = "data_roaming_type";
+
+ /**
+ * The current registered voice network operator name in long alphanumeric format.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorAlphaLong()}.
+ * @hide
+ */
+ public static final String VOICE_OPERATOR_ALPHA_LONG = "voice_operator_alpha_long";
+
+ /**
+ * The current registered operator name in short alphanumeric format.
+ * <p>
+ * In GSM/UMTS, short format can be up to 8 characters long. The current registered voice
+ * network operator name in long alphanumeric format.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorAlphaShort()}.
+ * @hide
+ */
+ public static final String VOICE_OPERATOR_ALPHA_SHORT = "voice_operator_alpha_short";
+
+ /**
+ * The current registered operator numeric id.
+ * <p>
+ * In GSM/UMTS, numeric format is 3 digit country code plus 2 or 3 digit
+ * network code.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorNumeric()}.
+ */
+ public static final String VOICE_OPERATOR_NUMERIC = "voice_operator_numeric";
+
+ /**
+ * The current registered data network operator name in long alphanumeric format.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorAlphaLong()}.
+ * @hide
+ */
+ public static final String DATA_OPERATOR_ALPHA_LONG = "data_operator_alpha_long";
+
+ /**
+ * The current registered data network operator name in short alphanumeric format.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorAlphaShort()}.
+ * @hide
+ */
+ public static final String DATA_OPERATOR_ALPHA_SHORT = "data_operator_alpha_short";
+
+ /**
+ * The current registered data network operator numeric id.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorNumeric()}.
+ * @hide
+ */
+ public static final String DATA_OPERATOR_NUMERIC = "data_operator_numeric";
+
+ /**
+ * This is the same as {@link ServiceState#getRilVoiceRadioTechnology()}.
+ * @hide
+ */
+ public static final String RIL_VOICE_RADIO_TECHNOLOGY = "ril_voice_radio_technology";
+
+ /**
+ * This is the same as {@link ServiceState#getRilDataRadioTechnology()}.
+ * @hide
+ */
+ public static final String RIL_DATA_RADIO_TECHNOLOGY = "ril_data_radio_technology";
+
+ /**
+ * This is the same as {@link ServiceState#getCssIndicator()}.
+ * @hide
+ */
+ public static final String CSS_INDICATOR = "css_indicator";
+
+ /**
+ * This is the same as {@link ServiceState#getCdmaNetworkId()}.
+ * @hide
+ */
+ public static final String NETWORK_ID = "network_id";
+
+ /**
+ * This is the same as {@link ServiceState#getCdmaSystemId()}.
+ * @hide
+ */
+ public static final String SYSTEM_ID = "system_id";
+
+ /**
+ * This is the same as {@link ServiceState#getCdmaRoamingIndicator()}.
+ * @hide
+ */
+ public static final String CDMA_ROAMING_INDICATOR = "cdma_roaming_indicator";
+
+ /**
+ * This is the same as {@link ServiceState#getCdmaDefaultRoamingIndicator()}.
+ * @hide
+ */
+ public static final String CDMA_DEFAULT_ROAMING_INDICATOR =
+ "cdma_default_roaming_indicator";
+
+ /**
+ * This is the same as {@link ServiceState#getCdmaEriIconIndex()}.
+ * @hide
+ */
+ public static final String CDMA_ERI_ICON_INDEX = "cdma_eri_icon_index";
+
+ /**
+ * This is the same as {@link ServiceState#getCdmaEriIconMode()}.
+ * @hide
+ */
+ public static final String CDMA_ERI_ICON_MODE = "cdma_eri_icon_mode";
+
+ /**
+ * This is the same as {@link ServiceState#isEmergencyOnly()}.
+ * @hide
+ */
+ public static final String IS_EMERGENCY_ONLY = "is_emergency_only";
+
+ /**
+ * This is the same as {@link ServiceState#getDataRoamingFromRegistration()}.
+ * @hide
+ */
+ public static final String IS_DATA_ROAMING_FROM_REGISTRATION =
+ "is_data_roaming_from_registration";
+
+ /**
+ * This is the same as {@link ServiceState#isUsingCarrierAggregation()}.
+ * @hide
+ */
+ public static final String IS_USING_CARRIER_AGGREGATION = "is_using_carrier_aggregation";
+
+ /**
+ * The current registered raw data network operator name in long alphanumeric format.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorAlphaLongRaw()}.
+ * @hide
+ */
+ public static final String OPERATOR_ALPHA_LONG_RAW = "operator_alpha_long_raw";
+
+ /**
+ * The current registered raw data network operator name in short alphanumeric format.
+ * <p>
+ * This is the same as {@link ServiceState#getOperatorAlphaShortRaw()}.
+ * @hide
+ */
+ public static final String OPERATOR_ALPHA_SHORT_RAW = "operator_alpha_short_raw";
+
+ private final HashMap<Integer, ServiceState> mServiceStates = new HashMap<>();
+ private static final String[] sColumns = {
+ VOICE_REG_STATE,
+ DATA_REG_STATE,
+ VOICE_ROAMING_TYPE,
+ DATA_ROAMING_TYPE,
+ VOICE_OPERATOR_ALPHA_LONG,
+ VOICE_OPERATOR_ALPHA_SHORT,
+ VOICE_OPERATOR_NUMERIC,
+ DATA_OPERATOR_ALPHA_LONG,
+ DATA_OPERATOR_ALPHA_SHORT,
+ DATA_OPERATOR_NUMERIC,
+ IS_MANUAL_NETWORK_SELECTION,
+ RIL_VOICE_RADIO_TECHNOLOGY,
+ RIL_DATA_RADIO_TECHNOLOGY,
+ CSS_INDICATOR,
+ NETWORK_ID,
+ SYSTEM_ID,
+ CDMA_ROAMING_INDICATOR,
+ CDMA_DEFAULT_ROAMING_INDICATOR,
+ CDMA_ERI_ICON_INDEX,
+ CDMA_ERI_ICON_MODE,
+ IS_EMERGENCY_ONLY,
+ IS_USING_CARRIER_AGGREGATION,
+ OPERATOR_ALPHA_LONG_RAW,
+ OPERATOR_ALPHA_SHORT_RAW,
+ };
+
+ @Override
+ public boolean onCreate() {
+ return true;
+ }
+
+ /**
+ * Returns the {@link ServiceState} information on specified subscription.
+ *
+ * @param subId whose subscriber id is returned
+ * @return the {@link ServiceState} information on specified subscription.
+ */
+ @VisibleForTesting
+ public ServiceState getServiceState(int subId) {
+ return mServiceStates.get(subId);
+ }
+
+ /**
+ * Returns the system's default subscription id.
+ *
+ * @return the "system" default subscription id.
+ */
+ @VisibleForTesting
+ public int getDefaultSubId() {
+ return SubscriptionManager.getDefaultSubscriptionId();
+ }
+
+ @Override
+ public Uri insert(Uri uri, ContentValues values) {
+ if (isPathPrefixMatch(uri, CONTENT_URI)) {
+ // Parse the subId
+ int subId = 0;
+ try {
+ subId = Integer.parseInt(uri.getLastPathSegment());
+ } catch (NumberFormatException e) {
+ Log.e(TAG, "insert: no subId provided in uri");
+ throw e;
+ }
+ Log.d(TAG, "subId=" + subId);
+
+ // handle DEFAULT_SUBSCRIPTION_ID
+ if (subId == SubscriptionManager.DEFAULT_SUBSCRIPTION_ID) {
+ subId = getDefaultSubId();
+ }
+
+ final Parcel p = Parcel.obtain();
+ final byte[] rawBytes = values.getAsByteArray(SERVICE_STATE);
+ p.unmarshall(rawBytes, 0, rawBytes.length);
+ p.setDataPosition(0);
+
+ // create the new service state
+ final ServiceState newSS = ServiceState.CREATOR.createFromParcel(p);
+
+ // notify listeners
+ // if ss is null (e.g. first service state update) we will notify for all fields
+ ServiceState ss = getServiceState(subId);
+ notifyChangeForSubIdAndField(getContext(), ss, newSS, subId);
+ notifyChangeForSubId(getContext(), ss, newSS, subId);
+
+ // store the new service state
+ mServiceStates.put(subId, newSS);
+ return uri;
+ }
+ return null;
+ }
+
+ @Override
+ public int delete(Uri uri, String selection, String[] selectionArgs) {
+ throw new RuntimeException("Not supported");
+ }
+
+ @Override
+ public int update(Uri uri, ContentValues values, String selection, String[] selectionArgs) {
+ throw new RuntimeException("Not supported");
+ }
+
+ @Override
+ public String getType(Uri uri) {
+ throw new RuntimeException("Not supported");
+ }
+
+ @Override
+ public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs,
+ String sortOrder) {
+ if (!isPathPrefixMatch(uri, CONTENT_URI)) {
+ throw new IllegalArgumentException("Invalid URI: " + uri);
+ } else {
+ // Parse the subId
+ int subId = 0;
+ try {
+ subId = Integer.parseInt(uri.getLastPathSegment());
+ } catch (NumberFormatException e) {
+ Log.d(TAG, "query: no subId provided in uri, using default.");
+ subId = getDefaultSubId();
+ }
+ Log.d(TAG, "subId=" + subId);
+
+ // handle DEFAULT_SUBSCRIPTION_ID
+ if (subId == SubscriptionManager.DEFAULT_SUBSCRIPTION_ID) {
+ subId = getDefaultSubId();
+ }
+
+ // Get the service state
+ ServiceState ss = getServiceState(subId);
+ if (ss == null) {
+ Log.d(TAG, "returning null");
+ return null;
+ }
+
+ // Build the result
+ final int voice_reg_state = ss.getState();
+ final int data_reg_state = ss.getDataRegistrationState();
+ final int voice_roaming_type = ss.getVoiceRoamingType();
+ final int data_roaming_type = ss.getDataRoamingType();
+ final String voice_operator_alpha_long = ss.getOperatorAlphaLong();
+ final String voice_operator_alpha_short = ss.getOperatorAlphaShort();
+ final String voice_operator_numeric = ss.getOperatorNumeric();
+ final String data_operator_alpha_long = ss.getOperatorAlphaLong();
+ final String data_operator_alpha_short = ss.getOperatorAlphaShort();
+ final String data_operator_numeric = ss.getOperatorNumeric();
+ final int is_manual_network_selection = (ss.getIsManualSelection()) ? 1 : 0;
+ final int ril_voice_radio_technology = ss.getRilVoiceRadioTechnology();
+ final int ril_data_radio_technology = ss.getRilDataRadioTechnology();
+ final int css_indicator = ss.getCssIndicator();
+ final int network_id = ss.getCdmaNetworkId();
+ final int system_id = ss.getCdmaSystemId();
+ final int cdma_roaming_indicator = ss.getCdmaRoamingIndicator();
+ final int cdma_default_roaming_indicator = ss.getCdmaDefaultRoamingIndicator();
+ final int cdma_eri_icon_index = ss.getCdmaEriIconIndex();
+ final int cdma_eri_icon_mode = ss.getCdmaEriIconMode();
+ final int is_emergency_only = (ss.isEmergencyOnly()) ? 1 : 0;
+ final int is_using_carrier_aggregation = (ss.isUsingCarrierAggregation()) ? 1 : 0;
+ final String operator_alpha_long_raw = ss.getOperatorAlphaLongRaw();
+ final String operator_alpha_short_raw = ss.getOperatorAlphaShortRaw();
+
+ return buildSingleRowResult(projection, sColumns, new Object[] {
+ voice_reg_state,
+ data_reg_state,
+ voice_roaming_type,
+ data_roaming_type,
+ voice_operator_alpha_long,
+ voice_operator_alpha_short,
+ voice_operator_numeric,
+ data_operator_alpha_long,
+ data_operator_alpha_short,
+ data_operator_numeric,
+ is_manual_network_selection,
+ ril_voice_radio_technology,
+ ril_data_radio_technology,
+ css_indicator,
+ network_id,
+ system_id,
+ cdma_roaming_indicator,
+ cdma_default_roaming_indicator,
+ cdma_eri_icon_index,
+ cdma_eri_icon_mode,
+ is_emergency_only,
+ is_using_carrier_aggregation,
+ operator_alpha_long_raw,
+ operator_alpha_short_raw,
+ });
+ }
+ }
+
+ private static Cursor buildSingleRowResult(String[] projection, String[] availableColumns,
+ Object[] data) {
+ if (projection == null) {
+ projection = availableColumns;
+ }
+ final MatrixCursor c = new MatrixCursor(projection, 1);
+ final RowBuilder row = c.newRow();
+ for (int i = 0; i < c.getColumnCount(); i++) {
+ final String columnName = c.getColumnName(i);
+ boolean found = false;
+ for (int j = 0; j < availableColumns.length; j++) {
+ if (availableColumns[j].equals(columnName)) {
+ row.add(data[j]);
+ found = true;
+ break;
+ }
+ }
+ if (!found) {
+ throw new IllegalArgumentException("Invalid column " + projection[i]);
+ }
+ }
+ return c;
+ }
+
+ /**
+ * Notify interested apps that certain fields of the ServiceState have changed.
+ *
+ * Apps which want to wake when specific fields change can use
+ * JobScheduler's TriggerContentUri. This replaces the waking functionality of the implicit
+ * broadcast of ACTION_SERVICE_STATE_CHANGED for apps targeting version O.
+ *
+ * We will only notify for certain fields. This is an intentional change from the behavior of
+ * the broadcast. Listeners will be notified when the voice or data registration state or
+ * roaming type changes.
+ */
+ @VisibleForTesting
+ public static void notifyChangeForSubIdAndField(Context context, ServiceState oldSS,
+ ServiceState newSS, int subId) {
+ final boolean firstUpdate = (oldSS == null) ? true : false;
+
+ // for every field, if the field has changed values, notify via the provider
+ if (firstUpdate || voiceRegStateChanged(oldSS, newSS)) {
+ context.getContentResolver().notifyChange(
+ getUriForSubscriptionIdAndField(subId, VOICE_REG_STATE),
+ /* observer= */ null, /* syncToNetwork= */ false);
+ }
+ if (firstUpdate || dataRegStateChanged(oldSS, newSS)) {
+ context.getContentResolver().notifyChange(
+ getUriForSubscriptionIdAndField(subId, DATA_REG_STATE), null, false);
+ }
+ if (firstUpdate || voiceRoamingTypeChanged(oldSS, newSS)) {
+ context.getContentResolver().notifyChange(
+ getUriForSubscriptionIdAndField(subId, VOICE_ROAMING_TYPE), null, false);
+ }
+ if (firstUpdate || dataRoamingTypeChanged(oldSS, newSS)) {
+ context.getContentResolver().notifyChange(
+ getUriForSubscriptionIdAndField(subId, DATA_ROAMING_TYPE), null, false);
+ }
+ }
+
+ private static boolean voiceRegStateChanged(ServiceState oldSS, ServiceState newSS) {
+ return oldSS.getState() != newSS.getState();
+ }
+
+ private static boolean dataRegStateChanged(ServiceState oldSS, ServiceState newSS) {
+ return oldSS.getDataRegistrationState() != newSS.getDataRegistrationState();
+ }
+
+ private static boolean voiceRoamingTypeChanged(ServiceState oldSS, ServiceState newSS) {
+ return oldSS.getVoiceRoamingType() != newSS.getVoiceRoamingType();
+ }
+
+ private static boolean dataRoamingTypeChanged(ServiceState oldSS, ServiceState newSS) {
+ return oldSS.getDataRoamingType() != newSS.getDataRoamingType();
+ }
+
+ /**
+ * Notify interested apps that the ServiceState has changed.
+ *
+ * Apps which want to wake when any field in the ServiceState has changed can use
+ * JobScheduler's TriggerContentUri. This replaces the waking functionality of the implicit
+ * broadcast of ACTION_SERVICE_STATE_CHANGED for apps targeting version O.
+ *
+ * We will only notify for certain fields. This is an intentional change from the behavior of
+ * the broadcast. Listeners will only be notified when the voice/data registration state or
+ * roaming type changes.
+ */
+ @VisibleForTesting
+ public static void notifyChangeForSubId(Context context, ServiceState oldSS, ServiceState newSS,
+ int subId) {
+ // if the voice or data registration or roaming state field has changed values, notify via
+ // the provider.
+ // If oldSS is null and newSS is not (e.g. first update of service state) this will also
+ // notify
+ if (oldSS == null || voiceRegStateChanged(oldSS, newSS) || dataRegStateChanged(oldSS, newSS)
+ || voiceRoamingTypeChanged(oldSS, newSS) || dataRoamingTypeChanged(oldSS, newSS)) {
+ context.getContentResolver().notifyChange(getUriForSubscriptionId(subId), null, false);
+ }
+ }
+
+ /**
+ * Test if this is a path prefix match against the given Uri. Verifies that
+ * scheme, authority, and atomic path segments match.
+ *
+ * Copied from frameworks/base/core/java/android/net/Uri.java
+ */
+ private boolean isPathPrefixMatch(Uri uriA, Uri uriB) {
+ if (!Objects.equals(uriA.getScheme(), uriB.getScheme())) return false;
+ if (!Objects.equals(uriA.getAuthority(), uriB.getAuthority())) return false;
+
+ List<String> segA = uriA.getPathSegments();
+ List<String> segB = uriB.getPathSegments();
+
+ final int size = segB.size();
+ if (segA.size() < size) return false;
+
+ for (int i = 0; i < size; i++) {
+ if (!Objects.equals(segA.get(i), segB.get(i))) {
+ return false;
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Used to insert a ServiceState into the ServiceStateProvider as a ContentValues instance.
+ *
+ * @param state the ServiceState to convert into ContentValues
+ * @return the convertedContentValues instance
+ * @hide
+ */
+ public static ContentValues getContentValuesForServiceState(ServiceState state) {
+ ContentValues values = new ContentValues();
+ final Parcel p = Parcel.obtain();
+ state.writeToParcel(p, 0);
+ // Turn the parcel to byte array. Safe to do this because the content values were never
+ // written into a persistent storage. ServiceStateProvider keeps values in the memory.
+ values.put(SERVICE_STATE, p.marshall());
+ return values;
+ }
+}
diff --git a/src/com/android/phone/settings/AccessibilitySettingsFragment.java b/src/com/android/phone/settings/AccessibilitySettingsFragment.java
index c9aa630..b665f4b 100644
--- a/src/com/android/phone/settings/AccessibilitySettingsFragment.java
+++ b/src/com/android/phone/settings/AccessibilitySettingsFragment.java
@@ -166,6 +166,17 @@
int rttMode = mButtonRtt.isChecked() ? 1 : 0;
Settings.Secure.putInt(mContext.getContentResolver(), Settings.Secure.RTT_CALLING_MODE,
rttMode);
+ // Update RTT config with IMS Manager if the always-on carrier config isn't set to true.
+ CarrierConfigManager configManager = (CarrierConfigManager) mContext.getSystemService(
+ Context.CARRIER_CONFIG_SERVICE);
+ for (int subId : SubscriptionController.getInstance().getActiveSubIdList(true)) {
+ if (!configManager.getConfigForSubId(subId).getBoolean(
+ CarrierConfigManager.KEY_IGNORE_RTT_MODE_SETTING_BOOL, false)) {
+ int phoneId = SubscriptionController.getInstance().getPhoneId(subId);
+ ImsManager imsManager = ImsManager.getInstance(getContext(), phoneId);
+ imsManager.setRttEnabled(mButtonRtt.isChecked());
+ }
+ }
return true;
}
diff --git a/src/com/android/services/telephony/CdmaConference.java b/src/com/android/services/telephony/CdmaConference.java
old mode 100755
new mode 100644
index 693fd16..32badd0
--- a/src/com/android/services/telephony/CdmaConference.java
+++ b/src/com/android/services/telephony/CdmaConference.java
@@ -73,6 +73,16 @@
}
@Override
+ public void onAnswer(int videoState) {
+ Log.e(this, new Exception(), "Answer not supported for CDMA conference call.");
+ }
+
+ @Override
+ public void onReject() {
+ Log.e(this, new Exception(), "Reject not supported for CDMA conference call.");
+ }
+
+ @Override
public void onHold() {
Log.e(this, new Exception(), "Hold not supported for CDMA conference call.");
}
diff --git a/src/com/android/services/telephony/ConferenceParticipantConnection.java b/src/com/android/services/telephony/ConferenceParticipantConnection.java
index ed92e7f..ac3928f 100644
--- a/src/com/android/services/telephony/ConferenceParticipantConnection.java
+++ b/src/com/android/services/telephony/ConferenceParticipantConnection.java
@@ -19,7 +19,7 @@
import android.net.Uri;
import android.telecom.Connection;
import android.telecom.DisconnectCause;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import android.telephony.SubscriptionInfo;
import android.text.TextUtils;
diff --git a/src/com/android/services/telephony/ImsConference.java b/src/com/android/services/telephony/ImsConference.java
index 4c3f9c9..dd000ce 100644
--- a/src/com/android/services/telephony/ImsConference.java
+++ b/src/com/android/services/telephony/ImsConference.java
@@ -30,7 +30,7 @@
import android.telecom.VideoProfile;
import android.telephony.CarrierConfigManager;
import android.telephony.PhoneNumberUtils;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import android.util.Pair;
import com.android.ims.internal.ConferenceParticipant;
@@ -199,6 +199,18 @@
TelephonyConnection telephonyConnection = (TelephonyConnection) c;
handleConferenceParticipantsUpdate(telephonyConnection, participants);
}
+
+ /**
+ * Handles request to play a ringback tone.
+ *
+ * @param c The connection.
+ * @param ringback Whether the ringback tone is to be played.
+ */
+ @Override
+ public void onRingbackRequested(android.telecom.Connection c, boolean ringback) {
+ Log.d(this, "onRingbackRequested ringback %s", ringback ? "Y" : "N");
+ setRingbackRequested(ringback);
+ }
};
/**
@@ -224,6 +236,11 @@
private TelecomAccountRegistry mTelecomAccountRegistry;
/**
+ * The participant with which Adhoc Conference call is getting formed.
+ */
+ private List<Uri> mParticipants;
+
+ /**
* The known conference participant connections. The HashMap is keyed by a Pair containing
* the handle and endpoint Uris.
* Access to the hashmap is protected by the {@link #mUpdateSyncRoot}.
@@ -383,6 +400,10 @@
conferenceProperties = changeBitmask(conferenceProperties,
Connection.PROPERTY_REMOTELY_HOSTED, !isConferenceHost());
+ conferenceProperties = changeBitmask(conferenceProperties,
+ Connection.PROPERTY_IS_ADHOC_CONFERENCE,
+ (properties & Connection.PROPERTY_IS_ADHOC_CONFERENCE) != 0);
+
return conferenceProperties;
}
@@ -422,6 +443,26 @@
return VideoProfile.STATE_AUDIO_ONLY;
}
+ public Connection getConferenceHost() {
+ return mConferenceHost;
+ }
+
+ /**
+ * @return The address's to which this Connection is currently communicating.
+ */
+ public final List<Uri> getParticipants() {
+ return mParticipants;
+ }
+
+ /**
+ * Sets the value of the {@link #getParticipants()}.
+ *
+ * @param address The new address's.
+ */
+ public final void setParticipants(List<Uri> address) {
+ mParticipants = address;
+ }
+
/**
* Invoked when the Conference and all its {@link Connection}s should be disconnected.
* <p>
@@ -481,6 +522,28 @@
}
/**
+ * Invoked when the conference is answered.
+ */
+ @Override
+ public void onAnswer(int videoState) {
+ if (mConferenceHost == null) {
+ return;
+ }
+ mConferenceHost.performAnswer(videoState);
+ }
+
+ /**
+ * Invoked when the conference is rejected.
+ */
+ @Override
+ public void onReject() {
+ if (mConferenceHost == null) {
+ return;
+ }
+ mConferenceHost.performReject();
+ }
+
+ /**
* Invoked when the conference should be put on hold.
*/
@Override
@@ -838,7 +901,8 @@
+ "newParticipantcount=%d", oldParticipantCount, newParticipantCount);
// If the single party call emulation fature flag is enabled, we can potentially treat
// the conference as a single party call when there is just one participant.
- if (mFeatureFlagProxy.isUsingSinglePartyCallEmulation()) {
+ if (mFeatureFlagProxy.isUsingSinglePartyCallEmulation() &&
+ !mConferenceHost.isAdhocConferenceCall()) {
if (oldParticipantCount != 1 && newParticipantCount == 1) {
// If number of participants goes to 1, emulate a single party call.
startEmulatingSinglePartyCall();
@@ -1173,11 +1237,13 @@
switch (state) {
case Connection.STATE_INITIALIZING:
case Connection.STATE_NEW:
- case Connection.STATE_RINGING:
// No-op -- not applicable.
break;
+ case Connection.STATE_RINGING:
+ setConferenceOnRinging();
+ break;
case Connection.STATE_DIALING:
- setDialing();
+ setConferenceOnDialing();
break;
case Connection.STATE_DISCONNECTED:
DisconnectCause disconnectCause;
@@ -1198,10 +1264,10 @@
destroyTelephonyConference();
break;
case Connection.STATE_ACTIVE:
- setActive();
+ setConferenceOnActive();
break;
case Connection.STATE_HOLDING:
- setOnHold();
+ setConferenceOnHold();
break;
}
}
diff --git a/src/com/android/services/telephony/ImsConferenceController.java b/src/com/android/services/telephony/ImsConferenceController.java
index 1e10055..8789ba8 100644
--- a/src/com/android/services/telephony/ImsConferenceController.java
+++ b/src/com/android/services/telephony/ImsConferenceController.java
@@ -22,7 +22,7 @@
import android.telecom.ConnectionService;
import android.telecom.DisconnectCause;
import android.telecom.PhoneAccountHandle;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import com.android.internal.telephony.Phone;
import com.android.internal.telephony.PhoneConstants;
@@ -52,8 +52,19 @@
Log.v(ImsConferenceController.class, "onDestroyed: %s", conference);
}
+ if (conference instanceof ImsConference) {
+ // Ims Conference call ended, so UE may now have the ability to initiate
+ // an Adhoc Conference call. Hence, try enabling adhoc conference capability
+ mTelecomAccountRegistry.refreshAdhocConference(true);
+ }
mImsConferences.remove(conference);
}
+
+ @Override
+ public void onStateChanged(Conference conference, int oldState, int newState) {
+ Log.v(this, "onStateChanged: Conference = " + conference);
+ recalculateConferenceable();
+ }
};
private final TelephonyConnection.TelephonyConnectionListener mTelephonyConnectionListener =
@@ -101,10 +112,11 @@
private final ArrayList<TelephonyConnection> mTelephonyConnections = new ArrayList<>();
/**
- * List of known {@link ImsConference}s. Realistically there will only ever be a single
- * concurrent IMS conference.
+ * List of known {@link ImsConference}s. There can be upto maximum two Ims conference calls.
+ * One conference call can be a host conference call and another conference call formed as a
+ * result of accepting incoming conference call.
*/
- private final ArrayList<ImsConference> mImsConferences = new ArrayList<>(1);
+ private final ArrayList<ImsConference> mImsConferences = new ArrayList<>(2);
private TelecomAccountRegistry mTelecomAccountRegistry;
@@ -122,6 +134,17 @@
mFeatureFlagProxy = featureFlagProxy;
}
+ void addConference(ImsConference conference) {
+ if (mImsConferences.contains(conference)) {
+ // Adding a duplicate realistically shouldn't happen.
+ Log.w(this, "addConference - conference already tracked; conference=%s", conference);
+ return;
+ }
+ mImsConferences.add(conference);
+ conference.addTelephonyConferenceListener(mConferenceListener);
+ recalculateConferenceable();
+ }
+
/**
* Adds a new connection to the IMS conference controller.
*
@@ -250,6 +273,11 @@
continue;
}
+ // Since UE cannot host two conference calls, remove the ability to initiate
+ // another conference call as there already exists a conference call, which
+ // is hosted on this device.
+ mTelecomAccountRegistry.refreshAdhocConference(false);
+
switch (conference.getState()) {
case Connection.STATE_ACTIVE:
//fall through
@@ -360,6 +388,10 @@
Log.v(this, "Start new ImsConference - connection: %s", connection);
}
+ if (connection.isAdhocConferenceCall()) {
+ Log.w(this, "start new ImsConference - control should never come here");
+ return;
+ }
// Make a clone of the connection which will become the Ims conference host connection.
// This is necessary since the Connection Service does not support removing a connection
// from Telecom. Instead we create a new instance and remove the old one from telecom.
diff --git a/src/com/android/services/telephony/PstnIncomingCallNotifier.java b/src/com/android/services/telephony/PstnIncomingCallNotifier.java
index 2dfeaed..d2dfab5 100644
--- a/src/com/android/services/telephony/PstnIncomingCallNotifier.java
+++ b/src/com/android/services/telephony/PstnIncomingCallNotifier.java
@@ -25,7 +25,7 @@
import android.telecom.PhoneAccount;
import android.telecom.PhoneAccountHandle;
import android.telecom.TelecomManager;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import android.text.TextUtils;
import com.android.internal.telephony.Call;
@@ -288,7 +288,11 @@
}
} else {
TelecomManager tm = mPhone.getContext().getSystemService(TelecomManager.class);
- tm.addNewIncomingCall(handle, extras);
+ if (connection.isMultiparty()) {
+ tm.addNewIncomingConference(handle, extras);
+ } else {
+ tm.addNewIncomingCall(handle, extras);
+ }
}
}
diff --git a/src/com/android/services/telephony/TelecomAccountRegistry.java b/src/com/android/services/telephony/TelecomAccountRegistry.java
index 5a1e6a6..919d3b2 100644
--- a/src/com/android/services/telephony/TelecomAccountRegistry.java
+++ b/src/com/android/services/telephony/TelecomAccountRegistry.java
@@ -41,7 +41,7 @@
import android.telecom.TelecomManager;
import android.telephony.CarrierConfigManager;
import android.telephony.PhoneStateListener;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import android.telephony.ServiceState;
import android.telephony.SubscriptionInfo;
import android.telephony.SubscriptionManager;
@@ -49,6 +49,8 @@
import android.telephony.TelephonyManager;
import android.telephony.ims.ImsException;
import android.telephony.ims.ImsMmTelManager;
+import android.telephony.ims.ImsReasonInfo;
+import android.telephony.ims.RegistrationManager;
import android.telephony.ims.feature.MmTelFeature;
import android.telephony.ims.stub.ImsRegistrationImplBase;
import android.text.TextUtils;
@@ -86,9 +88,11 @@
private final PstnPhoneCapabilitiesNotifier mPhoneCapabilitiesNotifier;
private boolean mIsEmergency;
private boolean mIsRttCapable;
+ private boolean mIsAdhocConfCapable;
private boolean mIsEmergencyPreferred;
private MmTelFeature.MmTelCapabilities mMmTelCapabilities;
private ImsMmTelManager.CapabilityCallback mMmtelCapabilityCallback;
+ private RegistrationManager.RegistrationCallback mImsRegistrationCallback;
private ImsMmTelManager mMmTelManager;
private final boolean mIsDummy;
private boolean mIsVideoCapable;
@@ -106,6 +110,7 @@
mPhone = phone;
mIsEmergency = isEmergency;
mIsDummy = isDummy;
+ mIsAdhocConfCapable = mPhone.isImsRegistered();
mAccount = registerPstnPhoneAccount(isEmergency, isDummy);
Log.i(this, "Registered phoneAccount: %s with handle: %s",
mAccount, mAccount.getAccountHandle());
@@ -138,15 +143,38 @@
updateRttCapability();
}
};
-
registerMmTelCapabilityCallback();
+
+ mImsRegistrationCallback = new RegistrationManager.RegistrationCallback() {
+ @Override
+ public void onRegistered(int imsRadioTech) {
+ updateAdhocConfCapability(true);
+ }
+
+ @Override
+ public void onRegistering(int imsRadioTech) {
+ updateAdhocConfCapability(false);
+ }
+
+ @Override
+ public void onUnregistered(ImsReasonInfo imsReasonInfo) {
+ updateAdhocConfCapability(false);
+ }
+ };
+ registerImsRegistrationCallback();
}
void teardown() {
mIncomingCallNotifier.teardown();
mPhoneCapabilitiesNotifier.teardown();
- if (mMmTelManager != null && mMmtelCapabilityCallback != null) {
- mMmTelManager.unregisterMmTelCapabilityCallback(mMmtelCapabilityCallback);
+ if (mMmTelManager != null) {
+ if (mMmtelCapabilityCallback != null) {
+ mMmTelManager.unregisterMmTelCapabilityCallback(mMmtelCapabilityCallback);
+ }
+
+ if (mImsRegistrationCallback != null) {
+ mMmTelManager.unregisterImsRegistrationCallback(mImsRegistrationCallback);
+ }
}
}
@@ -171,6 +199,25 @@
}
}
+ private void registerImsRegistrationCallback() {
+ if (mMmTelManager == null || mImsRegistrationCallback == null) {
+ return;
+ }
+
+ try {
+ mMmTelManager.registerImsRegistrationCallback(mContext.getMainExecutor(),
+ mImsRegistrationCallback);
+ } catch (ImsException e) {
+ Log.w(this, "registerImsRegistrationCallback: registration failed, no ImsService"
+ + " available. Exception: " + e.getMessage());
+ return;
+ } catch (IllegalArgumentException e) {
+ Log.w(this, "registerImsRegistrationCallback: registration failed, invalid"
+ + " subscription, Exception" + e.getMessage());
+ return;
+ }
+ }
+
/**
* Trigger re-registration of this account.
*/
@@ -226,6 +273,7 @@
// slotId from the subId or the phoneId in all instances.
SubscriptionInfo record =
mSubscriptionManager.getActiveSubscriptionInfo(subId);
+ TelephonyManager tm = mTelephonyManager.createForSubscriptionId(subId);
if (isEmergency) {
label = mContext.getResources().getString(R.string.sim_label_emergency_calls);
@@ -234,7 +282,7 @@
} else if (mTelephonyManager.getPhoneCount() == 1) {
// For single-SIM devices, we show the label and description as whatever the name of
// the network is.
- description = label = mTelephonyManager.getNetworkOperatorName();
+ description = label = tm.getNetworkOperatorName();
} else {
CharSequence subDisplayName = null;
@@ -321,6 +369,12 @@
extras.putAll(getPhoneAccountExtras());
}
+ if (mIsAdhocConfCapable && isCarrierAdhocConferenceCallSupported()) {
+ capabilities |= PhoneAccount.CAPABILITY_ADHOC_CONFERENCE_CALLING;
+ } else {
+ capabilities &= ~PhoneAccount.CAPABILITY_ADHOC_CONFERENCE_CALLING;
+ }
+
final boolean isHandoverFromSupported = mContext.getResources().getBoolean(
R.bool.config_support_handover_from);
if (isHandoverFromSupported && !isEmergency) {
@@ -511,6 +565,19 @@
}
/**
+ * Determines from carrier config whether adhoc conference calling is supported.
+ *
+ * @return {@code true} if adhoc conference calling is supported, {@code false} otherwise.
+ */
+ private boolean isCarrierAdhocConferenceCallSupported() {
+ PersistableBundle b =
+ PhoneGlobals.getInstance().getCarrierConfigForSubId(mPhone.getSubId());
+ return b != null &&
+ b.getBoolean(CarrierConfigManager.KEY_SUPPORT_ADHOC_CONFERENCE_CALLS_BOOL);
+ }
+
+
+ /**
* Determines from carrier config whether merging calls is supported.
*
* @return {@code true} if merging calls is supported, {@code false} otherwise.
@@ -664,6 +731,26 @@
}
}
+ public void updateAdhocConfCapability(boolean isAdhocConfCapable) {
+ synchronized (mAccountsLock) {
+ if (!mAccounts.contains(this)) {
+ // Account has already been torn down, don't try to register it again.
+ // This handles the case where teardown has already happened, and we got a Ims
+ // registartion update that lost the race for the mAccountsLock. In such a
+ // scenario by the time we get here, the original phone account could have been
+ // torn down.
+ return;
+ }
+
+ if (isAdhocConfCapable != mIsAdhocConfCapable) {
+ Log.i(this, "updateAdhocConfCapability - changed, new value: "
+ + isAdhocConfCapable);
+ mIsAdhocConfCapable = isAdhocConfCapable;
+ mAccount = registerPstnPhoneAccount(mIsEmergency, mIsDummy);
+ }
+ }
+ }
+
public void updateRttCapability() {
boolean isRttEnabled = isRttCurrentlySupported();
if (isRttEnabled != mIsRttCapable) {
@@ -1048,6 +1135,21 @@
return null;
}
+ public void refreshAdhocConference(boolean isEnableAdhocConf) {
+ synchronized (mAccountsLock) {
+ Log.v(this, "refreshAdhocConference isEnable = " + isEnableAdhocConf);
+ for (AccountEntry entry : mAccounts) {
+ boolean hasAdhocConfCapability = entry.mAccount.hasCapabilities(
+ PhoneAccount.CAPABILITY_ADHOC_CONFERENCE_CALLING);
+ if (!isEnableAdhocConf && hasAdhocConfCapability) {
+ entry.updateAdhocConfCapability(isEnableAdhocConf);
+ } else if (isEnableAdhocConf && !hasAdhocConfCapability) {
+ entry.updateAdhocConfCapability(entry.mPhone.isImsRegistered());
+ }
+ }
+ }
+ }
+
/**
* Returns whethere a the subscription associated with a {@link PhoneAccountHandle} is using a
* sim call manager.
diff --git a/src/com/android/services/telephony/TelephonyConference.java b/src/com/android/services/telephony/TelephonyConference.java
index afbe89d..d720639 100644
--- a/src/com/android/services/telephony/TelephonyConference.java
+++ b/src/com/android/services/telephony/TelephonyConference.java
@@ -93,6 +93,16 @@
}
@Override
+ public void onAnswer(int videoState) {
+ Log.e(this, new Exception(), "Answer not supported for GSM conference call.");
+ }
+
+ @Override
+ public void onReject() {
+ Log.e(this, new Exception(), "Reject not supported for GSM conference call.");
+ }
+
+ @Override
public void onMerge(Connection connection) {
try {
Phone phone = ((TelephonyConnection) connection).getPhone();
diff --git a/src/com/android/services/telephony/TelephonyConferenceBase.java b/src/com/android/services/telephony/TelephonyConferenceBase.java
index 5e7ecf6..1c81fb9 100644
--- a/src/com/android/services/telephony/TelephonyConferenceBase.java
+++ b/src/com/android/services/telephony/TelephonyConferenceBase.java
@@ -48,6 +48,14 @@
public void onConferenceMembershipChanged(Connection connection) {}
/**
+ * Listener called when there conference call state changes.
+ * @param conference The conference.
+ * @param oldState previous state of conference call.
+ * @param newState new state of conference call.
+ */
+ public void onStateChanged(Conference conference, int oldState, int newState) {}
+
+ /**
* Listener called when a conference is destroyed.
* @param conference The conference.
*/
@@ -129,6 +137,54 @@
}
/**
+ * Sets state to be on hold.
+ */
+ public final void setConferenceOnHold() {
+ int oldState = getState();
+ if (oldState == Connection.STATE_HOLDING) {
+ return;
+ }
+ setOnHold();
+ notifyStateChanged(oldState, getState());
+ }
+
+ /**
+ * Sets state to be dialing.
+ */
+ public final void setConferenceOnDialing() {
+ int oldState = getState();
+ if (oldState == Connection.STATE_DIALING) {
+ return;
+ }
+ setDialing();
+ notifyStateChanged(oldState, getState());
+ }
+
+ /**
+ * Sets state to be ringing.
+ */
+ public final void setConferenceOnRinging() {
+ int oldState = getState();
+ if (oldState == Connection.STATE_RINGING) {
+ return;
+ }
+ setRinging();
+ notifyStateChanged(oldState, getState());
+ }
+
+ /**
+ * Sets state to be active.
+ */
+ public final void setConferenceOnActive() {
+ int oldState = getState();
+ if (oldState == Connection.STATE_ACTIVE) {
+ return;
+ }
+ setActive();
+ notifyStateChanged(oldState, getState());
+ }
+
+ /**
* Updates RIL voice radio technology used for current conference after its creation.
*/
public void updateCallRadioTechAfterCreation() {
@@ -188,4 +244,12 @@
listener.onDestroyed(this);
}
}
+
+ private void notifyStateChanged(int oldState, int newState) {
+ if (oldState != newState) {
+ for (TelephonyConferenceListener listener : mListeners) {
+ listener.onStateChanged(this, oldState, newState);
+ }
+ }
+ }
}
diff --git a/src/com/android/services/telephony/TelephonyConnection.java b/src/com/android/services/telephony/TelephonyConnection.java
index 14f0cb8..f2b2244 100644
--- a/src/com/android/services/telephony/TelephonyConnection.java
+++ b/src/com/android/services/telephony/TelephonyConnection.java
@@ -40,7 +40,7 @@
import android.telephony.CarrierConfigManager;
import android.telephony.DisconnectCause;
import android.telephony.PhoneNumberUtils;
-import android.telephony.Rlog;
+import com.android.telephony.Rlog;
import android.telephony.ServiceState;
import android.telephony.ServiceState.RilRadioTechnology;
import android.telephony.SubscriptionManager;
@@ -114,6 +114,9 @@
private static final int MSG_ON_CONNECTION_EVENT = 19;
private static final int MSG_REDIAL_CONNECTION_CHANGED = 20;
+ private List<Uri> mParticipants;
+ private boolean mIsAdhocConferenceCall;
+
private final Handler mHandler = new Handler(Looper.getMainLooper()) {
@Override
public void handleMessage(Message msg) {
@@ -163,7 +166,9 @@
"not foreground connection, skipping");
return;
}
- setRingbackRequested((Boolean) ((AsyncResult) msg.obj).result);
+ boolean ringback = (Boolean) ((AsyncResult) msg.obj).result;
+ setRingbackRequested(ringback);
+ notifyRingbackRequested(ringback);
break;
case MSG_DISCONNECT:
updateState();
@@ -463,6 +468,7 @@
public void onVideoProviderChanged(android.telecom.Connection c,
Connection.VideoProvider videoProvider) {}
public void onVideoStateChanged(android.telecom.Connection c, int videoState) {}
+ public void onRingbackRequested(Connection c, boolean ringback) {}
}
private final PostDialListener mPostDialListener = new PostDialListener() {
@@ -876,14 +882,7 @@
@Override
public void onAnswer(int videoState) {
- Log.v(this, "onAnswer");
- if (isValidRingingCall() && getPhone() != null) {
- try {
- getPhone().acceptCall(videoState);
- } catch (CallStateException e) {
- Log.e(this, e, "Failed to accept call.");
- }
- }
+ performAnswer(videoState);
}
@Override
@@ -927,7 +926,11 @@
@Override
public void onReject() {
- Log.v(this, "onReject");
+ performReject();
+ }
+
+ public void performReject() {
+ Log.v(this, "performReject");
if (isValidRingingCall()) {
mHandler.obtainMessage(MSG_HANGUP, android.telephony.DisconnectCause.INCOMING_REJECTED)
.sendToTarget();
@@ -1001,6 +1004,17 @@
originalConnection.sendRttModifyResponse(textStream);
}
+ public void performAnswer(int videoState) {
+ Log.v(this, "performAnswer");
+ if (isValidRingingCall() && getPhone() != null) {
+ try {
+ getPhone().acceptCall(videoState);
+ } catch (CallStateException e) {
+ Log.e(this, e, "Failed to accept call.");
+ }
+ }
+ }
+
public void performHold() {
Log.v(this, "performHold");
// TODO: Can dialing calls be put on hold as well since they take up the
@@ -1167,6 +1181,8 @@
newProperties = changeBitmask(newProperties, PROPERTY_IS_RTT, isRtt());
newProperties = changeBitmask(newProperties, PROPERTY_NETWORK_IDENTIFIED_EMERGENCY_CALL,
isNetworkIdentifiedEmergencyCall());
+ newProperties = changeBitmask(newProperties, PROPERTY_IS_ADHOC_CONFERENCE,
+ isAdhocConferenceCall());
if (getConnectionProperties() != newProperties) {
setTelephonyConnectionProperties(newProperties);
@@ -1255,6 +1271,7 @@
setTelephonyVideoState(mOriginalConnection.getVideoState());
setOriginalConnectionCapabilities(mOriginalConnection.getConnectionCapabilities());
setIsNetworkIdentifiedEmergencyCall(mOriginalConnection.isNetworkIdentifiedEmergencyCall());
+ setIsAdhocConferenceCall(mOriginalConnection.isAdhocConference());
setAudioModeIsVoip(mOriginalConnection.getAudioModeIsVoip());
setTelephonyVideoProvider(mOriginalConnection.getVideoProvider());
setAudioQuality(mOriginalConnection.getAudioQuality());
@@ -1511,6 +1528,39 @@
return true;
}
+ /**
+ * @return The address's to which this Connection is currently communicating.
+ */
+ public final @Nullable List<Uri> getParticipants() {
+ return mParticipants;
+ }
+
+ /**
+ * Sets the value of the {@link #getParticipants()} property.
+ *
+ * @param address The participant address's.
+ */
+ public final void setParticipants(@Nullable List<Uri> address) {
+ mParticipants = address;
+ }
+
+ /**
+ * @return true if connection is adhocConference call else false.
+ */
+ public final boolean isAdhocConferenceCall() {
+ return mIsAdhocConferenceCall;
+ }
+
+ /**
+ * Sets the value of the {@link #isAdhocConferenceCall()} property.
+ *
+ * @param isAdhocConferenceCall represents if the call is adhoc conference call or not.
+ */
+ public void setIsAdhocConferenceCall(boolean isAdhocConferenceCall) {
+ mIsAdhocConferenceCall = isAdhocConferenceCall;
+ updateConnectionProperties();
+ }
+
private boolean canHoldImsCalls() {
PersistableBundle b = getCarrierConfig();
// Return true if the CarrierConfig is unavailable
@@ -2530,6 +2580,8 @@
}
sb.append(" confSupported:");
sb.append(mIsConferenceSupported ? "Y" : "N");
+ sb.append(" isAdhocConf:");
+ sb.append(isAdhocConferenceCall() ? "Y" : "N");
sb.append("]");
return sb.toString();
}
@@ -2855,6 +2907,16 @@
}
/**
+ * Notifies {@link TelephonyConnectionListener}s of a whether to play Ringback Tone or not.
+ * @param ringback Whether the ringback tone is to be played
+ */
+ private void notifyRingbackRequested(boolean ringback) {
+ for (TelephonyConnectionListener listener : mTelephonyListeners) {
+ listener.onRingbackRequested(this, ringback);
+ }
+ }
+
+ /**
* Notifies {@link TelephonyConnectionListener}s of changes to the video provider for a
* connection.
* @param videoProvider The new video provider.
diff --git a/src/com/android/services/telephony/TelephonyConnectionService.java b/src/com/android/services/telephony/TelephonyConnectionService.java
index b921466..73ea98d 100644
--- a/src/com/android/services/telephony/TelephonyConnectionService.java
+++ b/src/com/android/services/telephony/TelephonyConnectionService.java
@@ -516,6 +516,136 @@
return super.onUnbind(intent);
}
+ private Conference placeOutgoingConference(ConnectionRequest request,
+ Connection resultConnection, Phone phone) {
+ if (resultConnection instanceof TelephonyConnection) {
+ return placeOutgoingConference((TelephonyConnection) resultConnection, phone, request);
+ }
+ return null;
+ }
+
+ private Conference placeOutgoingConference(TelephonyConnection conferenceHostConnection,
+ Phone phone, ConnectionRequest request) {
+ updatePhoneAccount(conferenceHostConnection, phone);
+ com.android.internal.telephony.Connection originalConnection = null;
+ try {
+ originalConnection = phone.startConference(
+ getParticipantsToDial(request.getParticipants()),
+ new ImsPhone.ImsDialArgs.Builder()
+ .setVideoState(request.getVideoState())
+ .setRttTextStream(conferenceHostConnection.getRttTextStream())
+ .build());
+ } catch (CallStateException e) {
+ Log.e(this, e, "placeOutgoingConference, phone.startConference exception: " + e);
+ handleCallStateException(e, conferenceHostConnection, phone);
+ return null;
+ }
+
+ if (originalConnection == null) {
+ Log.d(this, "placeOutgoingConference, phone.startConference returned null");
+ conferenceHostConnection.setDisconnected(DisconnectCauseUtil.toTelecomDisconnectCause(
+ android.telephony.DisconnectCause.OUTGOING_FAILURE,
+ "conferenceHostConnection is null",
+ phone.getPhoneId()));
+ conferenceHostConnection.clearOriginalConnection();
+ conferenceHostConnection.destroy();
+ } else {
+ conferenceHostConnection.setOriginalConnection(originalConnection);
+ }
+
+ return prepareConference(conferenceHostConnection, request.getAccountHandle());
+ }
+
+ Conference prepareConference(Connection conn, PhoneAccountHandle phoneAccountHandle) {
+ if (!(conn instanceof TelephonyConnection)) {
+ Log.w(this, "prepareConference returning NULL conference");
+ return null;
+ }
+
+ TelephonyConnection connection = (TelephonyConnection)conn;
+ ImsConference conference = new ImsConference(TelecomAccountRegistry.getInstance(this),
+ mTelephonyConnectionServiceProxy, connection,
+ phoneAccountHandle, () -> true);
+ mImsConferenceController.addConference(conference);
+ conference.setVideoState(connection,
+ connection.getVideoState());
+ conference.setVideoProvider(connection,
+ connection.getVideoProvider());
+ conference.setStatusHints(connection.getStatusHints());
+ conference.setAddress(connection.getAddress(),
+ connection.getAddressPresentation());
+ conference.setCallerDisplayName(connection.getCallerDisplayName(),
+ connection.getCallerDisplayNamePresentation());
+ conference.setParticipants(connection.getParticipants());
+ return conference;
+ }
+
+ @Override
+ public @Nullable Conference onCreateIncomingConference(
+ @Nullable PhoneAccountHandle connectionManagerPhoneAccount,
+ @NonNull final ConnectionRequest request) {
+ Log.i(this, "onCreateIncomingConference, request: " + request);
+ Connection connection = onCreateIncomingConnection(connectionManagerPhoneAccount, request);
+ Log.d(this, "onCreateIncomingConference, connection: %s", connection);
+ if (connection == null) {
+ Log.i(this, "onCreateIncomingConference, implementation returned null connection.");
+ return Conference.createFailedConference(
+ new DisconnectCause(DisconnectCause.ERROR, "IMPL_RETURNED_NULL_CONNECTION"),
+ request.getAccountHandle());
+ }
+
+ final Phone phone = getPhoneForAccount(request.getAccountHandle(),
+ false /* isEmergencyCall*/, null /* not an emergency call */);
+ if (phone == null) {
+ Log.d(this, "onCreateIncomingConference, phone is null");
+ return Conference.createFailedConference(
+ DisconnectCauseUtil.toTelecomDisconnectCause(
+ android.telephony.DisconnectCause.OUT_OF_SERVICE,
+ "Phone is null"),
+ request.getAccountHandle());
+ }
+
+ return prepareConference(connection, request.getAccountHandle());
+ }
+
+ @Override
+ public @Nullable Conference onCreateOutgoingConference(
+ @Nullable PhoneAccountHandle connectionManagerPhoneAccount,
+ @NonNull final ConnectionRequest request) {
+ Log.i(this, "onCreateOutgoingConference, request: " + request);
+ Connection connection = onCreateOutgoingConnection(connectionManagerPhoneAccount, request);
+ Log.d(this, "onCreateOutgoingConference, connection: %s", connection);
+ if (connection == null) {
+ Log.i(this, "onCreateOutgoingConference, implementation returned null connection.");
+ return Conference.createFailedConference(
+ new DisconnectCause(DisconnectCause.ERROR, "IMPL_RETURNED_NULL_CONNECTION"),
+ request.getAccountHandle());
+ }
+
+ final Phone phone = getPhoneForAccount(request.getAccountHandle(),
+ false /* isEmergencyCall*/, null /* not an emergency call */);
+ if (phone == null) {
+ Log.d(this, "onCreateOutgoingConference, phone is null");
+ return Conference.createFailedConference(
+ DisconnectCauseUtil.toTelecomDisconnectCause(
+ android.telephony.DisconnectCause.OUT_OF_SERVICE,
+ "Phone is null"),
+ request.getAccountHandle());
+ }
+
+ return placeOutgoingConference(request, connection, phone);
+ }
+
+ private String[] getParticipantsToDial(List<Uri> participants) {
+ String[] participantsToDial = new String[participants.size()];
+ int i = 0;
+ for (Uri participant : participants) {
+ participantsToDial[i] = participant.getSchemeSpecificPart();
+ i++;
+ }
+ return participantsToDial;
+ }
+
@Override
public Connection onCreateOutgoingConnection(
PhoneAccountHandle connectionManagerPhoneAccount,
@@ -523,7 +653,9 @@
Log.i(this, "onCreateOutgoingConnection, request: " + request);
Uri handle = request.getAddress();
- if (handle == null) {
+ boolean isAdhocConference = request.isAdhocConferenceCall();
+
+ if (!isAdhocConference && handle == null) {
Log.d(this, "onCreateOutgoingConnection, handle is null");
return Connection.createFailedConnection(
mDisconnectCauseFactory.toTelecomDisconnectCause(
@@ -626,7 +758,6 @@
}
final String numberToDial = number;
-
final boolean isAirplaneModeOn = mDeviceState.isAirplaneModeOn(this);
boolean needToTurnOnRadio = (isEmergencyNumber && (!isRadioOn() || isAirplaneModeOn))
@@ -698,7 +829,15 @@
if (!isEmergencyNumber) {
final Connection resultConnection = getTelephonyConnection(request, numberToDial,
false, handle, phone);
- return placeOutgoingConnection(request, resultConnection, phone);
+ if (isAdhocConference) {
+ if (resultConnection instanceof TelephonyConnection) {
+ TelephonyConnection conn = (TelephonyConnection)resultConnection;
+ conn.setParticipants(request.getParticipants());
+ }
+ return resultConnection;
+ } else {
+ return placeOutgoingConnection(request, resultConnection, phone);
+ }
} else {
final Connection resultConnection = getTelephonyConnection(request, numberToDial,
true, handle, phone);
@@ -816,7 +955,8 @@
// TODO: Switch out the underlying connection instead of creating a new
// one and causing UI Jank.
boolean noActiveSimCard = SubscriptionController.getInstance()
- .getActiveSubInfoCount(phone.getContext().getOpPackageName()) == 0;
+ .getActiveSubInfoCount(phone.getContext().getOpPackageName(),
+ null) == 0;
// If there's no active sim card and the device is in emergency mode, use E account.
addExistingConnection(mPhoneUtilsProxy.makePstnPhoneAccountHandleWithPrefix(
phone, "", isEmergencyNumber && noActiveSimCard), repConnection);
@@ -895,7 +1035,7 @@
int dataNetType = phone.getServiceState().getDataNetworkType();
if (dataNetType == TelephonyManager.NETWORK_TYPE_LTE ||
dataNetType == TelephonyManager.NETWORK_TYPE_LTE_CA) {
- state = phone.getServiceState().getDataRegState();
+ state = phone.getServiceState().getDataRegistrationState();
}
}
@@ -981,7 +1121,7 @@
final TelephonyConnection connection =
createConnectionFor(phone, null, true /* isOutgoing */, request.getAccountHandle(),
- request.getTelecomCallId());
+ request.getTelecomCallId(), request.isAdhocConferenceCall());
if (connection == null) {
return Connection.createFailedConnection(
mDisconnectCauseFactory.toTelecomDisconnectCause(
@@ -994,6 +1134,8 @@
connection.setTelephonyVideoState(request.getVideoState());
connection.setRttTextStream(request.getRttTextStream());
connection.setTtyEnabled(isTtyModeEnabled);
+ connection.setIsAdhocConferenceCall(request.isAdhocConferenceCall());
+ connection.setParticipants(request.getParticipants());
return connection;
}
@@ -1042,7 +1184,8 @@
TelephonyConnection connection =
createConnectionFor(phone, originalConnection, false /* isOutgoing */,
- request.getAccountHandle(), request.getTelecomCallId());
+ request.getAccountHandle(), request.getTelecomCallId(),
+ request.isAdhocConferenceCall());
handleIncomingRtt(request, originalConnection);
if (connection == null) {
return Connection.createCanceledConnection();
@@ -1154,6 +1297,29 @@
connection.close();
}
+ /**
+ * Called by the {@link ConnectionService} when a newly created {@link Conference} has been
+ * added to the {@link ConnectionService} and sent to Telecom. Here it is safe to send
+ * connection events.
+ *
+ * @param conference the {@link Conference}.
+ */
+ @Override
+ public void onCreateConferenceComplete(Conference conference) {
+ if (conference instanceof ImsConference) {
+ ImsConference imsConference = (ImsConference)conference;
+ TelephonyConnection telephonyConnection =
+ (TelephonyConnection)(imsConference.getConferenceHost());
+ maybeSendInternationalCallEvent(telephonyConnection);
+ }
+ }
+
+ public void onCreateIncomingConferenceFailed(PhoneAccountHandle connectionManagerPhoneAccount,
+ ConnectionRequest request) {
+ Log.i(this, "onCreateIncomingConferenceFailed, request: " + request);
+ onCreateIncomingConnectionFailed(connectionManagerPhoneAccount, request);
+ }
+
@Override
public void triggerConferenceRecalculate() {
if (mTelephonyConferenceController.shouldRecalculate()) {
@@ -1470,6 +1636,12 @@
.OUTGOING_EMERGENCY_CALL_PLACED);
}
}
+ for (Conference c : getAllConferences()) {
+ if (c.getState() != Connection.STATE_DISCONNECTED
+ && c instanceof Conference) {
+ ((Conference) c).onDisconnect();
+ }
+ }
} else if (!isVideoCallHoldAllowed(phone)) {
// If we do not support holding ongoing video call for an outgoing
// emergency call, disconnect the ongoing video call.
@@ -1495,34 +1667,7 @@
}
} catch (CallStateException e) {
Log.e(this, e, "placeOutgoingConnection, phone.dial exception: " + e);
- int cause = android.telephony.DisconnectCause.OUTGOING_FAILURE;
- switch (e.getError()) {
- case CallStateException.ERROR_OUT_OF_SERVICE:
- cause = android.telephony.DisconnectCause.OUT_OF_SERVICE;
- break;
- case CallStateException.ERROR_POWER_OFF:
- cause = android.telephony.DisconnectCause.POWER_OFF;
- break;
- case CallStateException.ERROR_ALREADY_DIALING:
- cause = android.telephony.DisconnectCause.ALREADY_DIALING;
- break;
- case CallStateException.ERROR_CALL_RINGING:
- cause = android.telephony.DisconnectCause.CANT_CALL_WHILE_RINGING;
- break;
- case CallStateException.ERROR_CALLING_DISABLED:
- cause = android.telephony.DisconnectCause.CALLING_DISABLED;
- break;
- case CallStateException.ERROR_TOO_MANY_CALLS:
- cause = android.telephony.DisconnectCause.TOO_MANY_ONGOING_CALLS;
- break;
- case CallStateException.ERROR_OTASP_PROVISIONING_IN_PROCESS:
- cause = android.telephony.DisconnectCause.OTASP_PROVISIONING_IN_PROCESS;
- break;
- }
- connection.setTelephonyConnectionDisconnected(
- mDisconnectCauseFactory.toTelecomDisconnectCause(cause, e.getMessage(),
- phone.getPhoneId()));
- connection.close();
+ handleCallStateException(e, connection, phone);
return;
}
@@ -1576,12 +1721,55 @@
CarrierConfigManager.KEY_ALLOW_HOLD_CALL_DURING_EMERGENCY_BOOL, true);
}
+ private void handleCallStateException(CallStateException e, TelephonyConnection connection,
+ Phone phone) {
+ int cause = android.telephony.DisconnectCause.OUTGOING_FAILURE;
+ switch (e.getError()) {
+ case CallStateException.ERROR_OUT_OF_SERVICE:
+ cause = android.telephony.DisconnectCause.OUT_OF_SERVICE;
+ break;
+ case CallStateException.ERROR_POWER_OFF:
+ cause = android.telephony.DisconnectCause.POWER_OFF;
+ break;
+ case CallStateException.ERROR_ALREADY_DIALING:
+ cause = android.telephony.DisconnectCause.ALREADY_DIALING;
+ break;
+ case CallStateException.ERROR_CALL_RINGING:
+ cause = android.telephony.DisconnectCause.CANT_CALL_WHILE_RINGING;
+ break;
+ case CallStateException.ERROR_CALLING_DISABLED:
+ cause = android.telephony.DisconnectCause.CALLING_DISABLED;
+ break;
+ case CallStateException.ERROR_TOO_MANY_CALLS:
+ cause = android.telephony.DisconnectCause.TOO_MANY_ONGOING_CALLS;
+ break;
+ case CallStateException.ERROR_OTASP_PROVISIONING_IN_PROCESS:
+ cause = android.telephony.DisconnectCause.OTASP_PROVISIONING_IN_PROCESS;
+ break;
+ }
+ connection.setTelephonyConnectionDisconnected(
+ DisconnectCauseUtil.toTelecomDisconnectCause(cause, e.getMessage(),
+ phone.getPhoneId()));
+ connection.close();
+ }
+
private TelephonyConnection createConnectionFor(
Phone phone,
com.android.internal.telephony.Connection originalConnection,
boolean isOutgoing,
PhoneAccountHandle phoneAccountHandle,
String telecomCallId) {
+ return createConnectionFor(phone, originalConnection, isOutgoing, phoneAccountHandle,
+ telecomCallId, false);
+ }
+
+ private TelephonyConnection createConnectionFor(
+ Phone phone,
+ com.android.internal.telephony.Connection originalConnection,
+ boolean isOutgoing,
+ PhoneAccountHandle phoneAccountHandle,
+ String telecomCallId,
+ boolean isAdhocConference) {
TelephonyConnection returnConnection = null;
int phoneType = phone.getPhoneType();
if (phoneType == TelephonyManager.PHONE_TYPE_GSM) {
@@ -1592,8 +1780,10 @@
allowsMute, isOutgoing, telecomCallId);
}
if (returnConnection != null) {
- // Listen to Telephony specific callbacks from the connection
- returnConnection.addTelephonyConnectionListener(mTelephonyConnectionListener);
+ if (!isAdhocConference) {
+ // Listen to Telephony specific callbacks from the connection
+ returnConnection.addTelephonyConnectionListener(mTelephonyConnectionListener);
+ }
returnConnection.setVideoPauseSupported(
TelecomAccountRegistry.getInstance(this).isVideoPauseSupported(
phoneAccountHandle));
diff --git a/src/com/android/services/telephony/rcs/PresenceHelper.java b/src/com/android/services/telephony/rcs/PresenceHelper.java
new file mode 100644
index 0000000..5f7e35f
--- /dev/null
+++ b/src/com/android/services/telephony/rcs/PresenceHelper.java
@@ -0,0 +1,166 @@
+/*
+ * Copyright (C) 2020 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.
+ */
+
+package com.android.services.telephony.rcs;
+
+import android.annotation.Nullable;
+import android.content.Context;
+import android.telephony.SubscriptionManager;
+import android.util.Log;
+import android.util.SparseArray;
+
+import com.android.ims.RcsFeatureConnection;
+import com.android.ims.RcsFeatureManager;
+import com.android.internal.telephony.Phone;
+import com.android.internal.telephony.PhoneFactory;
+import com.android.internal.telephony.imsphone.ImsPhone;
+import com.android.internal.telephony.imsphone.ImsRcsStatusListener;
+import com.android.phone.R;
+import com.android.service.ims.presence.PresencePublication;
+import com.android.service.ims.presence.PresenceSubscriber;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+import java.util.Optional;
+
+class PresenceHelper {
+
+ private static final String LOG_TAG = "PresenceHelper";
+
+ private final Context mContext;
+ private final List<Phone> mPhones;
+
+ private final SparseArray<PresencePublication> mPresencePublications = new SparseArray<>();
+ private final SparseArray<PresenceSubscriber> mPresenceSubscribers = new SparseArray<>();
+
+ PresenceHelper(Context context) {
+ mContext = context;
+
+ // Get phones
+ Phone[] phoneAry = PhoneFactory.getPhones();
+ mPhones = (phoneAry != null) ? Arrays.asList(phoneAry) : new ArrayList<>();
+
+ initRcsPresencesInstance();
+ registerRcsConnectionStatus();
+
+ Log.i(LOG_TAG, "initialized: phone size=" + mPhones.size());
+ }
+
+ private void initRcsPresencesInstance() {
+ String[] volteError = mContext.getResources().getStringArray(
+ R.array.config_volte_provision_error_on_publish_response);
+ String[] rcsError = mContext.getResources().getStringArray(
+ R.array.config_rcs_provision_error_on_publish_response);
+
+ mPhones.forEach((phone) -> {
+ RcsFeatureConnection rcsConnection = getRcsFeatureConnection(phone);
+ // Initialize PresencePublication
+ mPresencePublications.put(
+ phone.getPhoneId(),
+ new PresencePublication(rcsConnection, mContext, volteError, rcsError));
+ // Initialize PresenceSubscriber
+ mPresenceSubscribers.put(
+ phone.getPhoneId(),
+ new PresenceSubscriber(rcsConnection, mContext, volteError, rcsError));
+ });
+ }
+
+ private @Nullable RcsFeatureConnection getRcsFeatureConnection(Phone phone) {
+ ImsPhone imsPhone = (ImsPhone) phone.getImsPhone();
+ if (imsPhone != null) {
+ RcsFeatureManager rcsFeatureManager = imsPhone.getRcsManager();
+ if (rcsFeatureManager != null) {
+ return rcsFeatureManager.getRcsFeatureConnection();
+ }
+ }
+ return null;
+ }
+
+ /*
+ * RcsFeatureManager in ImsPhone is not null only when RCS is connected. Register a callback to
+ * receive the RCS connection status.
+ */
+ private void registerRcsConnectionStatus() {
+ mPhones.forEach((phone) -> {
+ ImsPhone imsPhone = (ImsPhone) phone.getImsPhone();
+ if (imsPhone != null) {
+ imsPhone.setRcsStatusListener(mStatusListener);
+ }
+ });
+ }
+
+ /**
+ * The IMS RCS status listener to listen the status changed
+ */
+ private ImsRcsStatusListener mStatusListener = new ImsRcsStatusListener() {
+ @Override
+ public void onRcsConnected(int phoneId, RcsFeatureManager rcsFeatureManager) {
+ int subId = getSubscriptionId(phoneId);
+ if (subId == SubscriptionManager.INVALID_SUBSCRIPTION_ID) {
+ Log.e(LOG_TAG, "onRcsConnected: invalid subId, phoneId=" + phoneId);
+ return;
+ }
+
+ Log.i(LOG_TAG, "onRcsConnected: phoneId=" + phoneId + ", subId=" + subId);
+ RcsFeatureConnection connection = rcsFeatureManager.getRcsFeatureConnection();
+ PresencePublication presencePublication = getPresencePublication(phoneId);
+ if (presencePublication != null) {
+ Log.i(LOG_TAG, "Update PresencePublisher because RCS is connected");
+ presencePublication.updatePresencePublisher(subId, connection);
+ }
+ PresenceSubscriber presenceSubscriber = getPresenceSubscriber(phoneId);
+ if (presenceSubscriber != null) {
+ Log.i(LOG_TAG, "Update PresenceSubscriber because RCS is connected");
+ presenceSubscriber.updatePresenceSubscriber(subId, connection);
+ }
+ }
+
+ @Override
+ public void onRcsDisconnected(int phoneId) {
+ int subId = getSubscriptionId(phoneId);
+ Log.i(LOG_TAG, "onRcsDisconnected: phoneId=" + phoneId + ", subId=" + subId);
+ PresencePublication publication = getPresencePublication(phoneId);
+ if (publication != null) {
+ Log.i(LOG_TAG, "Remove PresencePublisher because RCS is disconnected");
+ publication.removePresencePublisher(subId);
+ }
+
+ PresenceSubscriber subscriber = getPresenceSubscriber(phoneId);
+ if (subscriber != null) {
+ Log.i(LOG_TAG, "Remove PresencePublisher because RCS is disconnected");
+ subscriber.removePresenceSubscriber(subId);
+ }
+ }
+ };
+
+ private int getSubscriptionId(int phoneId) {
+ Optional<Phone> phone = mPhones.stream()
+ .filter(p -> p.getPhoneId() == phoneId).findFirst();
+ if (phone.isPresent()) {
+ return phone.get().getSubId();
+ }
+ return SubscriptionManager.INVALID_SUBSCRIPTION_ID;
+ }
+
+ public @Nullable PresencePublication getPresencePublication(int phoneId) {
+ return mPresencePublications.get(phoneId);
+ }
+
+ public @Nullable PresenceSubscriber getPresenceSubscriber(int phoneId) {
+ return mPresenceSubscribers.get(phoneId);
+ }
+}
diff --git a/src/com/android/services/telephony/rcs/TelephonyRcsService.java b/src/com/android/services/telephony/rcs/TelephonyRcsService.java
new file mode 100644
index 0000000..74765d6
--- /dev/null
+++ b/src/com/android/services/telephony/rcs/TelephonyRcsService.java
@@ -0,0 +1,50 @@
+/*
+ * Copyright (C) 2020 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.
+ */
+
+package com.android.services.telephony.rcs;
+
+import android.content.Context;
+import android.util.Log;
+
+import com.android.service.ims.presence.PresencePublication;
+import com.android.service.ims.presence.PresenceSubscriber;
+
+/**
+ * Telephony RCS Service integrates PresencePublication and PresenceSubscriber into the service.
+ */
+public class TelephonyRcsService {
+
+ private static final String LOG_TAG = "TelephonyRcsService";
+
+ private final Context mContext;
+
+ // A helper class to manage the RCS Presences instances.
+ private final PresenceHelper mPresenceHelper;
+
+ public TelephonyRcsService(Context context) {
+ Log.i(LOG_TAG, "initialize");
+ mContext = context;
+ mPresenceHelper = new PresenceHelper(mContext);
+ }
+
+ private PresencePublication getPresencePublication(int phoneId) {
+ return mPresenceHelper.getPresencePublication(phoneId);
+ }
+
+ private PresenceSubscriber getPresenceSubscriber(int phoneId) {
+ return mPresenceHelper.getPresenceSubscriber(phoneId);
+ }
+}
diff --git a/tests/Android.bp b/tests/Android.bp
index 22b40b5..7ed234e 100644
--- a/tests/Android.bp
+++ b/tests/Android.bp
@@ -25,6 +25,7 @@
"telephony-common",
"android.test.base",
"ims-common",
+ "android.test.mock",
],
platform_apis: true,
certificate: "platform",
diff --git a/tests/src/com/android/phone/NumberVerificationManagerTest.java b/tests/src/com/android/phone/NumberVerificationManagerTest.java
index d476ba5..f7914ab 100644
--- a/tests/src/com/android/phone/NumberVerificationManagerTest.java
+++ b/tests/src/com/android/phone/NumberVerificationManagerTest.java
@@ -57,7 +57,7 @@
public void setUp() {
MockitoAnnotations.initMocks(this);
ServiceState ss = mock(ServiceState.class);
- when(ss.getVoiceRegState()).thenReturn(ServiceState.STATE_IN_SERVICE);
+ when(ss.getState()).thenReturn(ServiceState.STATE_IN_SERVICE);
when(mPhone1.getServiceState()).thenReturn(ss);
when(mPhone1.getForegroundCall()).thenReturn(mForegroundCall);
when(mPhone1.getRingingCall()).thenReturn(mRingingCall);
@@ -107,7 +107,7 @@
@Test
public void testNoPhoneInServiceFailure() throws Exception {
ServiceState ss = mock(ServiceState.class);
- when(ss.getVoiceRegState()).thenReturn(ServiceState.STATE_POWER_OFF);
+ when(ss.getState()).thenReturn(ServiceState.STATE_POWER_OFF);
when(mPhone1.getServiceState()).thenReturn(ss);
when(mPhone2.getServiceState()).thenReturn(ss);
NumberVerificationManager manager =
@@ -138,7 +138,7 @@
@Test
public void testVerificationWorksWithOnePhoneInService() throws Exception {
ServiceState ss = mock(ServiceState.class);
- when(ss.getVoiceRegState()).thenReturn(ServiceState.STATE_POWER_OFF);
+ when(ss.getState()).thenReturn(ServiceState.STATE_POWER_OFF);
when(mPhone1.getServiceState()).thenReturn(ss);
NumberVerificationManager manager =
new NumberVerificationManager(() -> new Phone[]{mPhone1, mPhone2});
diff --git a/tests/src/com/android/phone/PhoneGlobalsTest.java b/tests/src/com/android/phone/PhoneGlobalsTest.java
new file mode 100644
index 0000000..d45a890
--- /dev/null
+++ b/tests/src/com/android/phone/PhoneGlobalsTest.java
@@ -0,0 +1,71 @@
+/*
+ * Copyright (C) 2020 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.
+ */
+
+package com.android.phone;
+
+import static org.junit.Assert.assertEquals;
+
+import android.content.Context;
+import android.content.res.Configuration;
+import android.content.res.Resources;
+
+import androidx.test.InstrumentationRegistry;
+import androidx.test.runner.AndroidJUnit4;
+
+import com.android.TelephonyTestBase;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import java.util.Locale;
+
+
+@RunWith(AndroidJUnit4.class)
+public class PhoneGlobalsTest extends TelephonyTestBase {
+
+ @Before
+ public void setUp() throws Exception {
+ super.setUp();
+ }
+
+ @After
+ public void tearDown() throws Exception {
+ super.tearDown();
+ }
+
+ @Test
+ public void testGetImsResources() throws Exception {
+ // Do not use test context here, we are testing that overlaying for different locales works
+ // correctly
+ Context realContext = InstrumentationRegistry.getTargetContext();
+ String defaultImsMmtelPackage = getResourcesForLocale(realContext, Locale.US).getString(
+ R.string.config_ims_mmtel_package);
+ String defaultImsMmtelPackageUk = getResourcesForLocale(realContext, Locale.UK).getString(
+ R.string.config_ims_mmtel_package);
+ assertEquals("locales changed IMS package configuration!", defaultImsMmtelPackage,
+ defaultImsMmtelPackageUk);
+ }
+
+ private Resources getResourcesForLocale(Context context, Locale locale) {
+ Configuration config = new Configuration();
+ config.setToDefaults();
+ config.setLocale(locale);
+ Context localeContext = context.createConfigurationContext(config);
+ return localeContext.getResources();
+ }
+}
diff --git a/tests/src/com/android/phone/ServiceStateProviderTest.java b/tests/src/com/android/phone/ServiceStateProviderTest.java
new file mode 100644
index 0000000..574c0c9
--- /dev/null
+++ b/tests/src/com/android/phone/ServiceStateProviderTest.java
@@ -0,0 +1,307 @@
+/*
+ * Copyright (C) 2019 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.
+ */
+
+package com.android.phone;
+
+import static android.provider.Telephony.ServiceStateTable;
+import static android.provider.Telephony.ServiceStateTable.getUriForSubscriptionId;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.mockito.Mockito.doReturn;
+import static org.mockito.Mockito.mock;
+
+import android.content.Context;
+import android.content.pm.ProviderInfo;
+import android.database.ContentObserver;
+import android.database.Cursor;
+import android.net.Uri;
+import android.telephony.ServiceState;
+import android.telephony.SubscriptionManager;
+import android.test.mock.MockContentResolver;
+import android.test.suitebuilder.annotation.SmallTest;
+
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * Tests for simple queries of ServiceStateProvider.
+ *
+ * Build, install and run the tests by running the commands below:
+ * runtest --path <dir or file>
+ * runtest --path <dir or file> --test-method <testMethodName>
+ * e.g.)
+ * runtest --path tests/src/com/android/phone/ServiceStateProviderTest.java \
+ * --test-method testGetServiceState
+ */
+public class ServiceStateProviderTest {
+ private static final String TAG = "ServiceStateProviderTest";
+
+ private Context mContext;
+ private MockContentResolver mContentResolver;
+ private ServiceState mTestServiceState;
+ private ServiceState mTestServiceStateForSubId1;
+
+ private final String[] mTestProjection =
+ {
+ ServiceStateTable.VOICE_REG_STATE,
+ ServiceStateTable.DATA_REG_STATE,
+ ServiceStateTable.VOICE_OPERATOR_ALPHA_LONG,
+ ServiceStateTable.VOICE_OPERATOR_ALPHA_SHORT,
+ ServiceStateTable.VOICE_OPERATOR_NUMERIC,
+ ServiceStateTable.DATA_OPERATOR_ALPHA_LONG,
+ ServiceStateTable.DATA_OPERATOR_ALPHA_SHORT,
+ ServiceStateTable.DATA_OPERATOR_NUMERIC,
+ ServiceStateTable.IS_MANUAL_NETWORK_SELECTION,
+ ServiceStateTable.RIL_VOICE_RADIO_TECHNOLOGY,
+ ServiceStateTable.RIL_DATA_RADIO_TECHNOLOGY,
+ ServiceStateTable.CSS_INDICATOR,
+ ServiceStateTable.NETWORK_ID,
+ ServiceStateTable.SYSTEM_ID,
+ ServiceStateTable.CDMA_ROAMING_INDICATOR,
+ ServiceStateTable.CDMA_DEFAULT_ROAMING_INDICATOR,
+ ServiceStateTable.CDMA_ERI_ICON_INDEX,
+ ServiceStateTable.CDMA_ERI_ICON_MODE,
+ ServiceStateTable.IS_EMERGENCY_ONLY,
+ ServiceStateTable.IS_USING_CARRIER_AGGREGATION,
+ ServiceStateTable.OPERATOR_ALPHA_LONG_RAW,
+ ServiceStateTable.OPERATOR_ALPHA_SHORT_RAW,
+ };
+
+ @Before
+ public void setUp() throws Exception {
+ mContext = mock(Context.class);
+ mContentResolver = new MockContentResolver() {
+ @Override
+ public void notifyChange(Uri uri, ContentObserver observer, boolean syncToNetwork) {
+ throw new RuntimeException("notifyChange!");
+ }
+ };
+ doReturn(mContentResolver).when(mContext).getContentResolver();
+
+ mTestServiceState = new ServiceState();
+ mTestServiceState.setStateOutOfService();
+ mTestServiceStateForSubId1 = new ServiceState();
+ mTestServiceStateForSubId1.setStateOff();
+
+ // Mock out the actual phone state
+ ServiceStateProvider provider = new ServiceStateProvider() {
+ @Override
+ public ServiceState getServiceState(int subId) {
+ if (subId == 1) {
+ return mTestServiceStateForSubId1;
+ } else {
+ return mTestServiceState;
+ }
+ }
+
+ @Override
+ public int getDefaultSubId() {
+ return 0;
+ }
+ };
+ ProviderInfo providerInfo = new ProviderInfo();
+ providerInfo.authority = "service-state";
+ provider.attachInfoForTesting(mContext, providerInfo);
+ mContentResolver.addProvider("service-state", provider);
+ }
+
+ @Test
+ @SmallTest
+ public void testQueryServiceStateWithNoSubId() {
+ // Verify that when calling query with no subId in the uri the default ServiceState is
+ // returned.
+ // In this case the subId is set to 0 and the expected service state is
+ // mTestServiceState.
+ verifyServiceStateForSubId(ServiceStateTable.CONTENT_URI, mTestServiceState);
+ }
+
+ @Test
+ @SmallTest
+ public void testGetServiceStateWithDefaultSubId() {
+ // Verify that when calling with the DEFAULT_SUBSCRIPTION_ID the correct ServiceState is
+ // returned
+ // In this case the subId is set to 0 and the expected service state is
+ // mTestServiceState.
+ verifyServiceStateForSubId(
+ getUriForSubscriptionId(SubscriptionManager.DEFAULT_SUBSCRIPTION_ID),
+ mTestServiceState);
+ }
+
+ /**
+ * Test querying the service state for a given subId
+ */
+ @Test
+ @SmallTest
+ public void testGetServiceStateForSubId() {
+ // Verify that when calling with a specific subId the correct ServiceState is returned
+ // In this case the subId is set to 1 and the expected service state is
+ // mTestServiceStateForSubId1
+ verifyServiceStateForSubId(getUriForSubscriptionId(1), mTestServiceStateForSubId1);
+ }
+
+ private void verifyServiceStateForSubId(Uri uri, ServiceState ss) {
+ Cursor cursor = mContentResolver.query(uri, mTestProjection, "",
+ null, null);
+ assertNotNull(cursor);
+ cursor.moveToFirst();
+
+ final int voiceRegState = ss.getState();
+ final int dataRegState = ss.getDataRegistrationState();
+ final String voiceOperatorAlphaLong = ss.getOperatorAlphaLong();
+ final String voiceOperatorAlphaShort = ss.getOperatorAlphaShort();
+ final String voiceOperatorNumeric = ss.getOperatorNumeric();
+ final String dataOperatorAlphaLong = ss.getOperatorAlphaLong();
+ final String dataOperatorAlphaShort = ss.getOperatorAlphaShort();
+ final String dataOperatorNumeric = ss.getOperatorNumeric();
+ final int isManualNetworkSelection = (ss.getIsManualSelection()) ? 1 : 0;
+ final int rilVoiceRadioTechnology = ss.getRilVoiceRadioTechnology();
+ final int rilDataRadioTechnology = ss.getRilDataRadioTechnology();
+ final int cssIndicator = ss.getCssIndicator();
+ final int networkId = ss.getCdmaNetworkId();
+ final int systemId = ss.getCdmaSystemId();
+ final int cdmaRoamingIndicator = ss.getCdmaRoamingIndicator();
+ final int cdmaDefaultRoamingIndicator = ss.getCdmaDefaultRoamingIndicator();
+ final int cdmaEriIconIndex = ss.getCdmaEriIconIndex();
+ final int cdmaEriIconMode = ss.getCdmaEriIconMode();
+ final int isEmergencyOnly = (ss.isEmergencyOnly()) ? 1 : 0;
+ final int isUsingCarrierAggregation = (ss.isUsingCarrierAggregation()) ? 1 : 0;
+ final String operatorAlphaLongRaw = ss.getOperatorAlphaLongRaw();
+ final String operatorAlphaShortRaw = ss.getOperatorAlphaShortRaw();
+
+ assertEquals(voiceRegState, cursor.getInt(0));
+ assertEquals(dataRegState, cursor.getInt(1));
+ assertEquals(voiceOperatorAlphaLong, cursor.getString(2));
+ assertEquals(voiceOperatorAlphaShort, cursor.getString(3));
+ assertEquals(voiceOperatorNumeric, cursor.getString(4));
+ assertEquals(dataOperatorAlphaLong, cursor.getString(5));
+ assertEquals(dataOperatorAlphaShort, cursor.getString(6));
+ assertEquals(dataOperatorNumeric, cursor.getString(7));
+ assertEquals(isManualNetworkSelection, cursor.getInt(8));
+ assertEquals(rilVoiceRadioTechnology, cursor.getInt(9));
+ assertEquals(rilDataRadioTechnology, cursor.getInt(10));
+ assertEquals(cssIndicator, cursor.getInt(11));
+ assertEquals(networkId, cursor.getInt(12));
+ assertEquals(systemId, cursor.getInt(13));
+ assertEquals(cdmaRoamingIndicator, cursor.getInt(14));
+ assertEquals(cdmaDefaultRoamingIndicator, cursor.getInt(15));
+ assertEquals(cdmaEriIconIndex, cursor.getInt(16));
+ assertEquals(cdmaEriIconMode, cursor.getInt(17));
+ assertEquals(isEmergencyOnly, cursor.getInt(18));
+ assertEquals(isUsingCarrierAggregation, cursor.getInt(19));
+ assertEquals(operatorAlphaLongRaw, cursor.getString(20));
+ assertEquals(operatorAlphaShortRaw, cursor.getString(21));
+ }
+
+ /**
+ * Test that we don't notify for certain field changes. (e.g. we don't notify when the NetworkId
+ * or SystemId change) This is an intentional behavior change from the broadcast.
+ */
+ @Test
+ @SmallTest
+ public void testNoNotify() {
+ int subId = 0;
+
+ ServiceState oldSS = new ServiceState();
+ oldSS.setStateOutOfService();
+ oldSS.setCdmaSystemAndNetworkId(1, 1);
+
+ ServiceState newSS = new ServiceState();
+ newSS.setStateOutOfService();
+ newSS.setCdmaSystemAndNetworkId(0, 0);
+
+ // Test that notifyChange is not called for these fields
+ boolean notifyChangeWasCalled = false;
+ try {
+ ServiceStateProvider.notifyChangeForSubIdAndField(mContext, oldSS, newSS, subId);
+ } catch (RuntimeException e) {
+ final String message = e.getMessage();
+ if (message != null && message.equals("notifyChange!")) {
+ notifyChangeWasCalled = true;
+ }
+ }
+ assertFalse(notifyChangeWasCalled);
+ }
+
+ @Test
+ @SmallTest
+ public void testNotifyChanged() {
+ int subId = 0;
+
+ ServiceState oldSS = new ServiceState();
+ oldSS.setStateOutOfService();
+ oldSS.setVoiceRegState(ServiceState.STATE_OUT_OF_SERVICE);
+
+ ServiceState copyOfOldSS = new ServiceState();
+ copyOfOldSS.setStateOutOfService();
+ copyOfOldSS.setVoiceRegState(ServiceState.STATE_OUT_OF_SERVICE);
+
+ ServiceState newSS = new ServiceState();
+ newSS.setStateOutOfService();
+ newSS.setVoiceRegState(ServiceState.STATE_POWER_OFF);
+
+ // Test that notifyChange is not called with no change in notifyChangeForSubIdAndField
+ boolean notifyChangeWasCalled = false;
+ try {
+ ServiceStateProvider.notifyChangeForSubIdAndField(mContext, oldSS, copyOfOldSS, subId);
+ } catch (RuntimeException e) {
+ final String message = e.getMessage();
+ if (message != null && message.equals("notifyChange!")) {
+ notifyChangeWasCalled = true;
+ }
+ }
+ assertFalse(notifyChangeWasCalled);
+
+ // Test that notifyChange is not called with no change in notifyChangeForSubId
+ notifyChangeWasCalled = false;
+ try {
+ ServiceStateProvider.notifyChangeForSubId(mContext, oldSS, copyOfOldSS, subId);
+ } catch (RuntimeException e) {
+ final String message = e.getMessage();
+ if (message != null && message.equals("notifyChange!")) {
+ notifyChangeWasCalled = true;
+ }
+ }
+ assertFalse(notifyChangeWasCalled);
+
+ // Test that notifyChange is called by notifyChangeForSubIdAndField when the voice_reg_state
+ // changes
+ notifyChangeWasCalled = false;
+ try {
+ ServiceStateProvider.notifyChangeForSubIdAndField(mContext, oldSS, newSS, subId);
+ } catch (RuntimeException e) {
+ final String message = e.getMessage();
+ if (message != null && message.equals("notifyChange!")) {
+ notifyChangeWasCalled = true;
+ }
+ }
+ assertTrue(notifyChangeWasCalled);
+
+ // Test that notifyChange is called by notifyChangeForSubId when the voice_reg_state changes
+ notifyChangeWasCalled = false;
+ try {
+ ServiceStateProvider.notifyChangeForSubId(mContext, oldSS, newSS, subId);
+ } catch (RuntimeException e) {
+ final String message = e.getMessage();
+ if (message != null && message.equals("notifyChange!")) {
+ notifyChangeWasCalled = true;
+ }
+ }
+ assertTrue(notifyChangeWasCalled);
+ }
+}