Loading telephony/java/android/telephony/TelephonyManager.java +6 −1 Original line number Original line Diff line number Diff line Loading @@ -484,7 +484,12 @@ public class TelephonyManager { * @return true if a ICC card is present * @return true if a ICC card is present */ */ public boolean hasIccCard() { public boolean hasIccCard() { return PhoneFactory.getDefaultPhone().getIccCard().hasIccCard(); try { return getITelephony().hasIccCard(); } catch (RemoteException ex) { // Assume no ICC card if remote exception which shouldn't happen return false; } } } /** /** Loading telephony/java/com/android/internal/telephony/ITelephony.aidl +5 −0 Original line number Original line Diff line number Diff line Loading @@ -252,5 +252,10 @@ interface ITelephony { * Returns the network type * Returns the network type */ */ int getNetworkType(); int getNetworkType(); /** * Return true if an ICC card is present */ boolean hasIccCard(); } } Loading
telephony/java/android/telephony/TelephonyManager.java +6 −1 Original line number Original line Diff line number Diff line Loading @@ -484,7 +484,12 @@ public class TelephonyManager { * @return true if a ICC card is present * @return true if a ICC card is present */ */ public boolean hasIccCard() { public boolean hasIccCard() { return PhoneFactory.getDefaultPhone().getIccCard().hasIccCard(); try { return getITelephony().hasIccCard(); } catch (RemoteException ex) { // Assume no ICC card if remote exception which shouldn't happen return false; } } } /** /** Loading
telephony/java/com/android/internal/telephony/ITelephony.aidl +5 −0 Original line number Original line Diff line number Diff line Loading @@ -252,5 +252,10 @@ interface ITelephony { * Returns the network type * Returns the network type */ */ int getNetworkType(); int getNetworkType(); /** * Return true if an ICC card is present */ boolean hasIccCard(); } }