Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 85b84b7b authored by Amit Mahajan's avatar Amit Mahajan Committed by android-build-merger
Browse files

Merge "Revert "Don't assume 3GPP as active app on CDMA with LTE device"" am: e9f33e6f

am: df34b8d2

Change-Id: I4d1c3047cf3c789085d11a806db70b27bc6fc8e4
parents bfe07733 df34b8d2
Loading
Loading
Loading
Loading
+17 −2
Original line number Diff line number Diff line
@@ -167,17 +167,31 @@ public class IccCardProxy extends Handler implements IccCard {
     */
    private void updateQuietMode() {
        synchronized (mLock) {
            boolean oldQuietMode = mQuietMode;
            boolean newQuietMode;
            int cdmaSource = Phone.CDMA_SUBSCRIPTION_UNKNOWN;
            boolean isLteOnCdmaMode = TelephonyManager.getLteOnCdmaModeStatic()
                    == PhoneConstants.LTE_ON_CDMA_TRUE;
            if (mCurrentAppType == UiccController.APP_FAM_3GPP) {
                newQuietMode = false;
                if (DBG) log("updateQuietMode: 3GPP subscription -> newQuietMode=" + newQuietMode);
            } else {
                if (isLteOnCdmaMode) {
                    log("updateQuietMode: is cdma/lte device, force IccCardProxy into 3gpp mode");
                    mCurrentAppType = UiccController.APP_FAM_3GPP;
                }
                cdmaSource = mCdmaSSM != null ?
                        mCdmaSSM.getCdmaSubscriptionSource() : Phone.CDMA_SUBSCRIPTION_UNKNOWN;

                newQuietMode = (cdmaSource == Phone.CDMA_SUBSCRIPTION_NV)
                        && (mCurrentAppType == UiccController.APP_FAM_3GPP2);
                        && (mCurrentAppType == UiccController.APP_FAM_3GPP2)
                        && !isLteOnCdmaMode;
                if (DBG) {
                    log("updateQuietMode: cdmaSource=" + cdmaSource
                            + " mCurrentAppType=" + mCurrentAppType
                            + " isLteOnCdmaMode=" + isLteOnCdmaMode
                            + " newQuietMode=" + newQuietMode);
                }
            }

            if (mQuietMode == false && newQuietMode == true) {
@@ -198,7 +212,8 @@ public class IccCardProxy extends Handler implements IccCard {
            }
            if (DBG) {
                log("updateQuietMode: QuietMode is " + mQuietMode + " (app_type="
                    + mCurrentAppType + " cdmaSource=" + cdmaSource + ")");
                    + mCurrentAppType + " isLteOnCdmaMode=" + isLteOnCdmaMode
                    + " cdmaSource=" + cdmaSource + ")");
            }
            mInitialized = true;
            sendMessage(obtainMessage(EVENT_ICC_CHANGED));