summaryrefslogtreecommitdiffstats
path: root/telephony
diff options
context:
space:
mode:
authorStuart Scott <stuartscott@google.com>2015-01-28 12:35:43 -0800
committerStuart Scott <stuartscott@google.com>2015-01-28 13:06:12 -0800
commitd456ec4be1d2310c498dda2c7319562754ad643e (patch)
tree46f03fa8ace2e4d22fbcb523a5387e8ab0c14249 /telephony
parentcefcd81bdb47ca3196fe487e684880d70ff8073c (diff)
downloadframeworks_base-d456ec4be1d2310c498dda2c7319562754ad643e.zip
frameworks_base-d456ec4be1d2310c498dda2c7319562754ad643e.tar.gz
frameworks_base-d456ec4be1d2310c498dda2c7319562754ad643e.tar.bz2
Change getDeviceId to take phoneId.
bug:18827144 Change-Id: I32196f842504e63f4ddd45401e83e73afae81ad5
Diffstat (limited to 'telephony')
-rw-r--r--telephony/java/android/telephony/TelephonyManager.java8
-rw-r--r--telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl4
2 files changed, 4 insertions, 8 deletions
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index fe717dd..9bc1909 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -640,13 +640,9 @@ public class TelephonyManager {
*/
/** {@hide} */
public String getDeviceId(int slotId) {
- // FIXME methods taking slot id should not use subscription, instead us Uicc directly
- int[] subId = SubscriptionManager.getSubId(slotId);
- if (subId == null || subId.length == 0) {
- return null;
- }
+ // FIXME this assumes phoneId == slotId
try {
- return getSubscriberInfo().getDeviceIdForSubscriber(subId[0]);
+ return getSubscriberInfo().getDeviceIdForPhone(slotId);
} catch (RemoteException ex) {
return null;
} catch (NullPointerException ex) {
diff --git a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
index eec5333..c91a59c 100644
--- a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
+++ b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
@@ -33,10 +33,10 @@ interface IPhoneSubInfo {
String getNaiForSubscriber(int subId);
/**
- * Retrieves the unique device ID of a subId for the device, e.g., IMEI
+ * Retrieves the unique device ID of a phone for the device, e.g., IMEI
* for GSM phones.
*/
- String getDeviceIdForSubscriber(int subId);
+ String getDeviceIdForPhone(int phoneId);
/**
* Retrieves the IMEI.