Add multi-sim support for getCarrierPackageNamesForIntent.
resubmit of change Id100b7c4606287a1daa90092cd3c8a5a6519247d
Bug: 20268073
Change-Id: I8575681e17b1e1fdd308ad56b993ab348320f96c
diff --git a/src/com/android/phone/PhoneInterfaceManager.java b/src/com/android/phone/PhoneInterfaceManager.java
index 59eb996..1a8de66 100644
--- a/src/com/android/phone/PhoneInterfaceManager.java
+++ b/src/com/android/phone/PhoneInterfaceManager.java
@@ -2025,8 +2025,12 @@
}
@Override
- public List<String> getCarrierPackageNamesForIntent(Intent intent) {
- UiccCard card = UiccController.getInstance().getUiccCard(mPhone.getPhoneId());
+ public List<String> getCarrierPackageNamesForIntentAndPhone(Intent intent, int phoneId) {
+ if (!SubscriptionManager.isValidPhoneId(phoneId)) {
+ loge("phoneId " + phoneId + " is not valid.");
+ return null;
+ }
+ UiccCard card = UiccController.getInstance().getUiccCard(phoneId);
if (card == null) {
loge("getCarrierPackageNamesForIntent: No UICC");
return null ;