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

Commit 96aa3477 authored by Amit Mahajan's avatar Amit Mahajan Committed by android-build-merger
Browse files

Merge "Re-register for IccRecordEvents on phone type change."

am: 161b5e29

Change-Id: I529fd3f97eb5c005019f5a0bab33c677a1c3f3ce
parents 066ec719 161b5e29
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -440,6 +440,15 @@ public class GsmCdmaPhone extends Phone {
        mSST.updatePhoneType();
        setPhoneName(precisePhoneType == PhoneConstants.PHONE_TYPE_GSM ? "GSM" : "CDMA");
        onUpdateIccAvailability();
        // if is possible that onUpdateIccAvailability() does not unregister and re-register for
        // ICC events, for example if mUiccApplication does not change which can happen if phone
        // type is transitioning from CDMA to GSM but 3gpp2 application was not available.
        // To handle such cases, unregister and re-register here. They still need to be called in
        // onUpdateIccAvailability(), since in normal cases register/unregister calls can be on
        // different IccRecords objects. Here they are on the same IccRecords object.
        unregisterForIccRecordEvents();
        registerForIccRecordEvents();

        mCT.updatePhoneType();

        int radioState = mCi.getRadioState();