Loading src/java/com/android/internal/telephony/cdma/CdmaServiceStateTracker.java +26 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.app.AlarmManager; import android.content.ContentResolver; import android.content.Context; import android.content.Intent; import android.content.res.Resources; import android.database.ContentObserver; import android.os.AsyncResult; import android.os.Build; Loading Loading @@ -583,6 +584,14 @@ public class CdmaServiceStateTracker extends ServiceStateTracker { // mOperatorAlphaLong contains the ERI text String plmn = mSS.getOperatorAlphaLong(); int combinedRegState = getCombinedRegState(); if (combinedRegState == ServiceState.STATE_OUT_OF_SERVICE) { plmn = Resources.getSystem().getText(com.android.internal. R.string.lockscreen_carrier_default).toString(); if (DBG) log("updateSpnDisplay: radio is on but out " + "of service, set plmn='" + plmn + "'"); } if (!TextUtils.equals(plmn, mCurPlmn)) { // Allow A blank plmn, "" to set showPlmn to true. Previously, we // would set showPlmn to true only if plmn was not empty, i.e. was not Loading @@ -606,6 +615,23 @@ public class CdmaServiceStateTracker extends ServiceStateTracker { mCurPlmn = plmn; } /** * Consider dataRegState if voiceRegState is OOS to determine SPN to be * displayed */ private int getCombinedRegState() { int regState = mSS.getVoiceRegState(); int dataRegState = mSS.getDataRegState(); if ((regState == ServiceState.STATE_OUT_OF_SERVICE) && (dataRegState == ServiceState.STATE_IN_SERVICE)) { log("getCombinedRegState: return STATE_IN_SERVICE as Data is in service"); regState = dataRegState; } return regState; } @Override protected Phone getPhone() { return mPhone; Loading Loading
src/java/com/android/internal/telephony/cdma/CdmaServiceStateTracker.java +26 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.app.AlarmManager; import android.content.ContentResolver; import android.content.Context; import android.content.Intent; import android.content.res.Resources; import android.database.ContentObserver; import android.os.AsyncResult; import android.os.Build; Loading Loading @@ -583,6 +584,14 @@ public class CdmaServiceStateTracker extends ServiceStateTracker { // mOperatorAlphaLong contains the ERI text String plmn = mSS.getOperatorAlphaLong(); int combinedRegState = getCombinedRegState(); if (combinedRegState == ServiceState.STATE_OUT_OF_SERVICE) { plmn = Resources.getSystem().getText(com.android.internal. R.string.lockscreen_carrier_default).toString(); if (DBG) log("updateSpnDisplay: radio is on but out " + "of service, set plmn='" + plmn + "'"); } if (!TextUtils.equals(plmn, mCurPlmn)) { // Allow A blank plmn, "" to set showPlmn to true. Previously, we // would set showPlmn to true only if plmn was not empty, i.e. was not Loading @@ -606,6 +615,23 @@ public class CdmaServiceStateTracker extends ServiceStateTracker { mCurPlmn = plmn; } /** * Consider dataRegState if voiceRegState is OOS to determine SPN to be * displayed */ private int getCombinedRegState() { int regState = mSS.getVoiceRegState(); int dataRegState = mSS.getDataRegState(); if ((regState == ServiceState.STATE_OUT_OF_SERVICE) && (dataRegState == ServiceState.STATE_IN_SERVICE)) { log("getCombinedRegState: return STATE_IN_SERVICE as Data is in service"); regState = dataRegState; } return regState; } @Override protected Phone getPhone() { return mPhone; Loading