summaryrefslogtreecommitdiffstats
path: root/telephony
diff options
context:
space:
mode:
authorJean-Baptiste Queru <jbq@google.com>2010-07-29 14:53:42 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2010-07-29 14:53:42 -0700
commit969907f3f59cf9420c3bd9d672b509196cf82cbe (patch)
tree0194799454e8b13f3402714b682d2544d3457e9a /telephony
parentff74e22b59f8157580953fcd69e3c32aa8f68eb2 (diff)
parentf0fa8416e13b2885b858b6974b101c70833e4729 (diff)
downloadframeworks_base-969907f3f59cf9420c3bd9d672b509196cf82cbe.zip
frameworks_base-969907f3f59cf9420c3bd9d672b509196cf82cbe.tar.gz
frameworks_base-969907f3f59cf9420c3bd9d672b509196cf82cbe.tar.bz2
am f0fa8416: Merge "Make hasIccCard return true if RUIM card is present."
Merge commit 'f0fa8416e13b2885b858b6974b101c70833e4729' into gingerbread-plus-aosp * commit 'f0fa8416e13b2885b858b6974b101c70833e4729': Make hasIccCard return true if RUIM card is present.
Diffstat (limited to 'telephony')
-rw-r--r--telephony/java/com/android/internal/telephony/IccCard.java9
1 files changed, 4 insertions, 5 deletions
diff --git a/telephony/java/com/android/internal/telephony/IccCard.java b/telephony/java/com/android/internal/telephony/IccCard.java
index d3a34ec..90f9e8c 100644
--- a/telephony/java/com/android/internal/telephony/IccCard.java
+++ b/telephony/java/com/android/internal/telephony/IccCard.java
@@ -672,12 +672,11 @@ public abstract class IccCard {
* @return true if a ICC card is present
*/
public boolean hasIccCard() {
- boolean isIccPresent;
- if (mPhone.getPhoneName().equals("GSM")) {
- return mIccCardStatus.getCardState().isCardPresent();
- } else {
- // TODO: Make work with a CDMA device with a RUIM card.
+ if (mIccCardStatus == null) {
return false;
+ } else {
+ // Returns ICC card status for both GSM and CDMA mode
+ return mIccCardStatus.getCardState().isCardPresent();
}
}