Loading src/java/com/android/internal/telephony/InboundSmsHandler.java +20 −0 Original line number Original line Diff line number Diff line Loading @@ -27,6 +27,7 @@ import android.content.ContentUris; import android.content.ContentValues; import android.content.ContentValues; import android.content.Context; import android.content.Context; import android.content.Intent; import android.content.Intent; import android.content.SharedPreferences; import android.database.Cursor; import android.database.Cursor; import android.database.SQLException; import android.database.SQLException; import android.net.Uri; import android.net.Uri; Loading @@ -35,6 +36,7 @@ import android.os.Build; import android.os.Message; import android.os.Message; import android.os.PowerManager; import android.os.PowerManager; import android.os.SystemProperties; import android.os.SystemProperties; import android.preference.PreferenceManager; import android.provider.Telephony; import android.provider.Telephony; import android.provider.Telephony.Sms.Intents; import android.provider.Telephony.Sms.Intents; import android.telephony.Rlog; import android.telephony.Rlog; Loading Loading @@ -811,6 +813,24 @@ public abstract class InboundSmsHandler extends StateMachine { return (PHONE_TYPE_CDMA == activePhone); return (PHONE_TYPE_CDMA == activePhone); } } protected void storeVoiceMailCount() { // Store the voice mail count in persistent memory. String imsi = mPhone.getSubscriberId(); int mwi = mPhone.getVoiceMessageCount(); log("Storing Voice Mail Count = " + mwi + " for imsi = " + imsi + " for mVmCountKey = " + ((PhoneBase)mPhone).VM_COUNT + " vmId = " + ((PhoneBase)mPhone).VM_ID + " in preferences."); SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mContext); SharedPreferences.Editor editor = sp.edit(); editor.putInt(mPhone.VM_COUNT, mwi); editor.putString(mPhone.VM_ID, imsi); editor.commit(); } /** /** * Handler for an {@link InboundSmsTracker} broadcast. Deletes PDUs from the raw table and * Handler for an {@link InboundSmsTracker} broadcast. Deletes PDUs from the raw table and * logs the broadcast duration (as an error if the other receivers were especially slow). * logs the broadcast duration (as an error if the other receivers were especially slow). Loading src/java/com/android/internal/telephony/PhoneBase.java +19 −15 Original line number Original line Diff line number Diff line Loading @@ -133,6 +133,11 @@ public abstract class PhoneBase extends Handler implements Phone { // Key used to read/write current CLIR setting // Key used to read/write current CLIR setting public static final String CLIR_KEY = "clir_key"; public static final String CLIR_KEY = "clir_key"; // Key used for storing voice mail count public static final String VM_COUNT = "vm_count_key"; // Key used to read/write the ID for storing the voice mail public static final String VM_ID = "vm_id_key"; // Key used to read/write "disable DNS server check" pref (used for testing) // Key used to read/write "disable DNS server check" pref (used for testing) public static final String DNS_SERVER_CHECK_DISABLED_KEY = "dns_server_check_disabled_key"; public static final String DNS_SERVER_CHECK_DISABLED_KEY = "dns_server_check_disabled_key"; Loading @@ -141,6 +146,7 @@ public abstract class PhoneBase extends Handler implements Phone { /* Instance Variables */ /* Instance Variables */ public CommandsInterface mCi; public CommandsInterface mCi; private int mVmCount = 0; boolean mDnsCheckDisabled; boolean mDnsCheckDisabled; public DcTrackerBase mDcTracker; public DcTrackerBase mDcTracker; boolean mDoesRilSendMultipleCallRing; boolean mDoesRilSendMultipleCallRing; Loading Loading @@ -886,9 +892,9 @@ public abstract class PhoneBase extends Handler implements Phone { } } @Override @Override /** @return true if there are messages waiting, false otherwise. */ public boolean getMessageWaitingIndicator() { public boolean getMessageWaitingIndicator() { IccRecords r = mIccRecords.get(); return mVmCount != 0; return (r != null) ? r.getVoiceMessageWaiting() : false; } } @Override @Override Loading Loading @@ -1061,9 +1067,17 @@ public abstract class PhoneBase extends Handler implements Phone { public abstract int getPhoneType(); public abstract int getPhoneType(); /** @hide */ /** @hide */ /** @return number of voicemails */ @Override @Override public int getVoiceMessageCount(){ public int getVoiceMessageCount(){ return 0; return mVmCount; } /** sets the voice mail count of the phone and notifies listeners. */ public void setVoiceMessageCount(int countWaiting) { mVmCount = countWaiting; // notify listeners of voice mail notifyMessageWaitingIndicator(); } } /** /** Loading Loading @@ -1429,19 +1443,9 @@ public abstract class PhoneBase extends Handler implements Phone { return mCi.getLteOnCdmaMode(); return mCi.getLteOnCdmaMode(); } } /** * Sets the SIM voice message waiting indicator records. * @param line GSM Subscriber Profile Number, one-based. Only '1' is supported * @param countWaiting The number of messages waiting, if known. Use * -1 to indicate that an unknown number of * messages are waiting */ @Override public void setVoiceMessageWaiting(int line, int countWaiting) { public void setVoiceMessageWaiting(int line, int countWaiting) { IccRecords r = mIccRecords.get(); // This function should be overridden by class GSMPhone and CDMAPhone. if (r != null) { Rlog.e(LOG_TAG, "Error! This function should never be executed, inactive Phone."); r.setVoiceMessageWaiting(line, countWaiting); } } } /** /** Loading src/java/com/android/internal/telephony/TelephonyCapabilities.java +4 −4 Original line number Original line Diff line number Diff line Loading @@ -71,12 +71,12 @@ public class TelephonyCapabilities { } } /** /** * Return true if the current phone can retrieve the voice message count. * Return true if the current phone supports voice message count. * * and the count is available * Currently this is assumed to be true on CDMA phones and false otherwise. * Both CDMA and GSM phones support voice message count */ */ public static boolean supportsVoiceMessageCount(Phone phone) { public static boolean supportsVoiceMessageCount(Phone phone) { return (phone.getPhoneType() == PhoneConstants.PHONE_TYPE_CDMA); return (phone.getVoiceMessageCount() != -1); } } /** /** Loading src/java/com/android/internal/telephony/cdma/CDMAPhone.java +23 −42 Original line number Original line Diff line number Diff line Loading @@ -93,7 +93,6 @@ public class CDMAPhone extends PhoneBase { // Default Emergency Callback Mode exit timer // Default Emergency Callback Mode exit timer private static final int DEFAULT_ECM_EXIT_TIMER_VALUE = 300000; private static final int DEFAULT_ECM_EXIT_TIMER_VALUE = 300000; protected static final String VM_COUNT_CDMA = "vm_count_key_cdma"; protected static final String VM_NUMBER_CDMA = "vm_number_key_cdma"; protected static final String VM_NUMBER_CDMA = "vm_number_key_cdma"; private String mVmNumber = null; private String mVmNumber = null; Loading Loading @@ -223,7 +222,7 @@ public class CDMAPhone extends PhoneBase { updateCurrentCarrierInProvider(operatorNumeric); updateCurrentCarrierInProvider(operatorNumeric); // Notify voicemails. // Notify voicemails. notifier.notifyMessageWaitingChanged(this); updateVoiceMail(); } } @Override @Override Loading Loading @@ -387,12 +386,6 @@ public class CDMAPhone extends PhoneBase { throw new CallStateException("Sending UUS information NOT supported in CDMA!"); throw new CallStateException("Sending UUS information NOT supported in CDMA!"); } } @Override public boolean getMessageWaitingIndicator() { return (getVoiceMessageCount() > 0); } @Override @Override public List<? extends MmiCode> public List<? extends MmiCode> getPendingMmiCodes() { getPendingMmiCodes() { Loading Loading @@ -874,21 +867,15 @@ public class CDMAPhone extends PhoneBase { return number; return number; } } /* Returns Number of Voicemails // pending voice mail count updated after phone creation * @hide private void updateVoiceMail() { */ setVoiceMessageCount(getStoredVoiceMessageCount()); @Override public int getVoiceMessageCount() { IccRecords r = mIccRecords.get(); int voicemailCount = (r != null) ? r.getVoiceMessageCount() : 0; // If mRuimRecords.getVoiceMessageCount returns zero, then there is possibility // that phone was power cycled and would have lost the voicemail count. // So get the count from preferences. if (voicemailCount == 0) { SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(getContext()); voicemailCount = sp.getInt(VM_COUNT_CDMA, 0); } } return voicemailCount; /** gets the voice mail count from preferences */ private int getStoredVoiceMessageCount() { SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mContext); return (sp.getInt(VM_COUNT, 0)); } } @Override @Override Loading Loading @@ -1144,11 +1131,6 @@ public class CDMAPhone extends PhoneBase { } } break; break; case EVENT_ICC_RECORD_EVENTS: ar = (AsyncResult)msg.obj; processIccRecordEvents((Integer)ar.result); break; case EVENT_EXIT_EMERGENCY_CALLBACK_RESPONSE:{ case EVENT_EXIT_EMERGENCY_CALLBACK_RESPONSE:{ handleExitEmergencyCallbackMode(msg); handleExitEmergencyCallbackMode(msg); } } Loading Loading @@ -1264,18 +1246,6 @@ public class CDMAPhone extends PhoneBase { } } } } private void processIccRecordEvents(int eventCode) { switch (eventCode) { case RuimRecords.EVENT_MWI: notifyMessageWaitingIndicator(); break; default: Rlog.e(LOG_TAG,"Unknown icc records event code " + eventCode); break; } } /** /** * Handles the call to get the subscription source * Handles the call to get the subscription source * * Loading Loading @@ -1673,7 +1643,6 @@ public class CDMAPhone extends PhoneBase { if (r == null) { if (r == null) { return; return; } } r.registerForRecordsEvents(this, EVENT_ICC_RECORD_EVENTS, null); r.registerForRecordsLoaded(this, EVENT_RUIM_RECORDS_LOADED, null); r.registerForRecordsLoaded(this, EVENT_RUIM_RECORDS_LOADED, null); } } Loading @@ -1682,10 +1651,22 @@ public class CDMAPhone extends PhoneBase { if (r == null) { if (r == null) { return; return; } } r.unregisterForRecordsEvents(this); r.unregisterForRecordsLoaded(this); r.unregisterForRecordsLoaded(this); } } /** * Sets the SIM voice message count * @param line Subscriber Profile Number, one-based. Only '1' is supported * @param countWaiting The number of messages waiting, if known. Use * -1 to indicate that an unknown number of * messages are waiting * This is a wrapper function for setVoiceMessageCount */ @Override public void setVoiceMessageWaiting(int line, int countWaiting) { setVoiceMessageCount(countWaiting); } protected void log(String s) { protected void log(String s) { if (DBG) if (DBG) Rlog.d(LOG_TAG, s); Rlog.d(LOG_TAG, s); Loading src/java/com/android/internal/telephony/cdma/CdmaInboundSmsHandler.java +12 −8 Original line number Original line Diff line number Diff line Loading @@ -20,11 +20,9 @@ package com.android.internal.telephony.cdma; import android.app.Activity; import android.app.Activity; import android.content.Context; import android.content.Context; import android.content.SharedPreferences; import android.content.res.Resources; import android.content.res.Resources; import android.os.Message; import android.os.Message; import android.os.SystemProperties; import android.os.SystemProperties; import android.preference.PreferenceManager; import android.provider.Telephony.Sms.Intents; import android.provider.Telephony.Sms.Intents; import android.telephony.SmsCbMessage; import android.telephony.SmsCbMessage; Loading Loading @@ -272,12 +270,18 @@ public class CdmaInboundSmsHandler extends InboundSmsHandler { int voicemailCount = sms.getNumOfVoicemails(); int voicemailCount = sms.getNumOfVoicemails(); if (DBG) log("Voicemail count=" + voicemailCount); if (DBG) log("Voicemail count=" + voicemailCount); // Store the voicemail count in preferences. // range check SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mContext); if (voicemailCount < 0) { SharedPreferences.Editor editor = sp.edit(); voicemailCount = -1; editor.putInt(CDMAPhone.VM_COUNT_CDMA, voicemailCount); } else if (voicemailCount > 99) { editor.apply(); // C.S0015-B v2, 4.5.12 mPhone.setVoiceMessageWaiting(1, voicemailCount); // range: 0-99 voicemailCount = 99; } // update voice mail count in phone mPhone.setVoiceMessageCount(voicemailCount); // store voice mail count in preferences storeVoiceMailCount(); } } /** /** Loading Loading
src/java/com/android/internal/telephony/InboundSmsHandler.java +20 −0 Original line number Original line Diff line number Diff line Loading @@ -27,6 +27,7 @@ import android.content.ContentUris; import android.content.ContentValues; import android.content.ContentValues; import android.content.Context; import android.content.Context; import android.content.Intent; import android.content.Intent; import android.content.SharedPreferences; import android.database.Cursor; import android.database.Cursor; import android.database.SQLException; import android.database.SQLException; import android.net.Uri; import android.net.Uri; Loading @@ -35,6 +36,7 @@ import android.os.Build; import android.os.Message; import android.os.Message; import android.os.PowerManager; import android.os.PowerManager; import android.os.SystemProperties; import android.os.SystemProperties; import android.preference.PreferenceManager; import android.provider.Telephony; import android.provider.Telephony; import android.provider.Telephony.Sms.Intents; import android.provider.Telephony.Sms.Intents; import android.telephony.Rlog; import android.telephony.Rlog; Loading Loading @@ -811,6 +813,24 @@ public abstract class InboundSmsHandler extends StateMachine { return (PHONE_TYPE_CDMA == activePhone); return (PHONE_TYPE_CDMA == activePhone); } } protected void storeVoiceMailCount() { // Store the voice mail count in persistent memory. String imsi = mPhone.getSubscriberId(); int mwi = mPhone.getVoiceMessageCount(); log("Storing Voice Mail Count = " + mwi + " for imsi = " + imsi + " for mVmCountKey = " + ((PhoneBase)mPhone).VM_COUNT + " vmId = " + ((PhoneBase)mPhone).VM_ID + " in preferences."); SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mContext); SharedPreferences.Editor editor = sp.edit(); editor.putInt(mPhone.VM_COUNT, mwi); editor.putString(mPhone.VM_ID, imsi); editor.commit(); } /** /** * Handler for an {@link InboundSmsTracker} broadcast. Deletes PDUs from the raw table and * Handler for an {@link InboundSmsTracker} broadcast. Deletes PDUs from the raw table and * logs the broadcast duration (as an error if the other receivers were especially slow). * logs the broadcast duration (as an error if the other receivers were especially slow). Loading
src/java/com/android/internal/telephony/PhoneBase.java +19 −15 Original line number Original line Diff line number Diff line Loading @@ -133,6 +133,11 @@ public abstract class PhoneBase extends Handler implements Phone { // Key used to read/write current CLIR setting // Key used to read/write current CLIR setting public static final String CLIR_KEY = "clir_key"; public static final String CLIR_KEY = "clir_key"; // Key used for storing voice mail count public static final String VM_COUNT = "vm_count_key"; // Key used to read/write the ID for storing the voice mail public static final String VM_ID = "vm_id_key"; // Key used to read/write "disable DNS server check" pref (used for testing) // Key used to read/write "disable DNS server check" pref (used for testing) public static final String DNS_SERVER_CHECK_DISABLED_KEY = "dns_server_check_disabled_key"; public static final String DNS_SERVER_CHECK_DISABLED_KEY = "dns_server_check_disabled_key"; Loading @@ -141,6 +146,7 @@ public abstract class PhoneBase extends Handler implements Phone { /* Instance Variables */ /* Instance Variables */ public CommandsInterface mCi; public CommandsInterface mCi; private int mVmCount = 0; boolean mDnsCheckDisabled; boolean mDnsCheckDisabled; public DcTrackerBase mDcTracker; public DcTrackerBase mDcTracker; boolean mDoesRilSendMultipleCallRing; boolean mDoesRilSendMultipleCallRing; Loading Loading @@ -886,9 +892,9 @@ public abstract class PhoneBase extends Handler implements Phone { } } @Override @Override /** @return true if there are messages waiting, false otherwise. */ public boolean getMessageWaitingIndicator() { public boolean getMessageWaitingIndicator() { IccRecords r = mIccRecords.get(); return mVmCount != 0; return (r != null) ? r.getVoiceMessageWaiting() : false; } } @Override @Override Loading Loading @@ -1061,9 +1067,17 @@ public abstract class PhoneBase extends Handler implements Phone { public abstract int getPhoneType(); public abstract int getPhoneType(); /** @hide */ /** @hide */ /** @return number of voicemails */ @Override @Override public int getVoiceMessageCount(){ public int getVoiceMessageCount(){ return 0; return mVmCount; } /** sets the voice mail count of the phone and notifies listeners. */ public void setVoiceMessageCount(int countWaiting) { mVmCount = countWaiting; // notify listeners of voice mail notifyMessageWaitingIndicator(); } } /** /** Loading Loading @@ -1429,19 +1443,9 @@ public abstract class PhoneBase extends Handler implements Phone { return mCi.getLteOnCdmaMode(); return mCi.getLteOnCdmaMode(); } } /** * Sets the SIM voice message waiting indicator records. * @param line GSM Subscriber Profile Number, one-based. Only '1' is supported * @param countWaiting The number of messages waiting, if known. Use * -1 to indicate that an unknown number of * messages are waiting */ @Override public void setVoiceMessageWaiting(int line, int countWaiting) { public void setVoiceMessageWaiting(int line, int countWaiting) { IccRecords r = mIccRecords.get(); // This function should be overridden by class GSMPhone and CDMAPhone. if (r != null) { Rlog.e(LOG_TAG, "Error! This function should never be executed, inactive Phone."); r.setVoiceMessageWaiting(line, countWaiting); } } } /** /** Loading
src/java/com/android/internal/telephony/TelephonyCapabilities.java +4 −4 Original line number Original line Diff line number Diff line Loading @@ -71,12 +71,12 @@ public class TelephonyCapabilities { } } /** /** * Return true if the current phone can retrieve the voice message count. * Return true if the current phone supports voice message count. * * and the count is available * Currently this is assumed to be true on CDMA phones and false otherwise. * Both CDMA and GSM phones support voice message count */ */ public static boolean supportsVoiceMessageCount(Phone phone) { public static boolean supportsVoiceMessageCount(Phone phone) { return (phone.getPhoneType() == PhoneConstants.PHONE_TYPE_CDMA); return (phone.getVoiceMessageCount() != -1); } } /** /** Loading
src/java/com/android/internal/telephony/cdma/CDMAPhone.java +23 −42 Original line number Original line Diff line number Diff line Loading @@ -93,7 +93,6 @@ public class CDMAPhone extends PhoneBase { // Default Emergency Callback Mode exit timer // Default Emergency Callback Mode exit timer private static final int DEFAULT_ECM_EXIT_TIMER_VALUE = 300000; private static final int DEFAULT_ECM_EXIT_TIMER_VALUE = 300000; protected static final String VM_COUNT_CDMA = "vm_count_key_cdma"; protected static final String VM_NUMBER_CDMA = "vm_number_key_cdma"; protected static final String VM_NUMBER_CDMA = "vm_number_key_cdma"; private String mVmNumber = null; private String mVmNumber = null; Loading Loading @@ -223,7 +222,7 @@ public class CDMAPhone extends PhoneBase { updateCurrentCarrierInProvider(operatorNumeric); updateCurrentCarrierInProvider(operatorNumeric); // Notify voicemails. // Notify voicemails. notifier.notifyMessageWaitingChanged(this); updateVoiceMail(); } } @Override @Override Loading Loading @@ -387,12 +386,6 @@ public class CDMAPhone extends PhoneBase { throw new CallStateException("Sending UUS information NOT supported in CDMA!"); throw new CallStateException("Sending UUS information NOT supported in CDMA!"); } } @Override public boolean getMessageWaitingIndicator() { return (getVoiceMessageCount() > 0); } @Override @Override public List<? extends MmiCode> public List<? extends MmiCode> getPendingMmiCodes() { getPendingMmiCodes() { Loading Loading @@ -874,21 +867,15 @@ public class CDMAPhone extends PhoneBase { return number; return number; } } /* Returns Number of Voicemails // pending voice mail count updated after phone creation * @hide private void updateVoiceMail() { */ setVoiceMessageCount(getStoredVoiceMessageCount()); @Override public int getVoiceMessageCount() { IccRecords r = mIccRecords.get(); int voicemailCount = (r != null) ? r.getVoiceMessageCount() : 0; // If mRuimRecords.getVoiceMessageCount returns zero, then there is possibility // that phone was power cycled and would have lost the voicemail count. // So get the count from preferences. if (voicemailCount == 0) { SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(getContext()); voicemailCount = sp.getInt(VM_COUNT_CDMA, 0); } } return voicemailCount; /** gets the voice mail count from preferences */ private int getStoredVoiceMessageCount() { SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mContext); return (sp.getInt(VM_COUNT, 0)); } } @Override @Override Loading Loading @@ -1144,11 +1131,6 @@ public class CDMAPhone extends PhoneBase { } } break; break; case EVENT_ICC_RECORD_EVENTS: ar = (AsyncResult)msg.obj; processIccRecordEvents((Integer)ar.result); break; case EVENT_EXIT_EMERGENCY_CALLBACK_RESPONSE:{ case EVENT_EXIT_EMERGENCY_CALLBACK_RESPONSE:{ handleExitEmergencyCallbackMode(msg); handleExitEmergencyCallbackMode(msg); } } Loading Loading @@ -1264,18 +1246,6 @@ public class CDMAPhone extends PhoneBase { } } } } private void processIccRecordEvents(int eventCode) { switch (eventCode) { case RuimRecords.EVENT_MWI: notifyMessageWaitingIndicator(); break; default: Rlog.e(LOG_TAG,"Unknown icc records event code " + eventCode); break; } } /** /** * Handles the call to get the subscription source * Handles the call to get the subscription source * * Loading Loading @@ -1673,7 +1643,6 @@ public class CDMAPhone extends PhoneBase { if (r == null) { if (r == null) { return; return; } } r.registerForRecordsEvents(this, EVENT_ICC_RECORD_EVENTS, null); r.registerForRecordsLoaded(this, EVENT_RUIM_RECORDS_LOADED, null); r.registerForRecordsLoaded(this, EVENT_RUIM_RECORDS_LOADED, null); } } Loading @@ -1682,10 +1651,22 @@ public class CDMAPhone extends PhoneBase { if (r == null) { if (r == null) { return; return; } } r.unregisterForRecordsEvents(this); r.unregisterForRecordsLoaded(this); r.unregisterForRecordsLoaded(this); } } /** * Sets the SIM voice message count * @param line Subscriber Profile Number, one-based. Only '1' is supported * @param countWaiting The number of messages waiting, if known. Use * -1 to indicate that an unknown number of * messages are waiting * This is a wrapper function for setVoiceMessageCount */ @Override public void setVoiceMessageWaiting(int line, int countWaiting) { setVoiceMessageCount(countWaiting); } protected void log(String s) { protected void log(String s) { if (DBG) if (DBG) Rlog.d(LOG_TAG, s); Rlog.d(LOG_TAG, s); Loading
src/java/com/android/internal/telephony/cdma/CdmaInboundSmsHandler.java +12 −8 Original line number Original line Diff line number Diff line Loading @@ -20,11 +20,9 @@ package com.android.internal.telephony.cdma; import android.app.Activity; import android.app.Activity; import android.content.Context; import android.content.Context; import android.content.SharedPreferences; import android.content.res.Resources; import android.content.res.Resources; import android.os.Message; import android.os.Message; import android.os.SystemProperties; import android.os.SystemProperties; import android.preference.PreferenceManager; import android.provider.Telephony.Sms.Intents; import android.provider.Telephony.Sms.Intents; import android.telephony.SmsCbMessage; import android.telephony.SmsCbMessage; Loading Loading @@ -272,12 +270,18 @@ public class CdmaInboundSmsHandler extends InboundSmsHandler { int voicemailCount = sms.getNumOfVoicemails(); int voicemailCount = sms.getNumOfVoicemails(); if (DBG) log("Voicemail count=" + voicemailCount); if (DBG) log("Voicemail count=" + voicemailCount); // Store the voicemail count in preferences. // range check SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mContext); if (voicemailCount < 0) { SharedPreferences.Editor editor = sp.edit(); voicemailCount = -1; editor.putInt(CDMAPhone.VM_COUNT_CDMA, voicemailCount); } else if (voicemailCount > 99) { editor.apply(); // C.S0015-B v2, 4.5.12 mPhone.setVoiceMessageWaiting(1, voicemailCount); // range: 0-99 voicemailCount = 99; } // update voice mail count in phone mPhone.setVoiceMessageCount(voicemailCount); // store voice mail count in preferences storeVoiceMailCount(); } } /** /** Loading