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

Commit 0b655654 authored by Jack Yu's avatar Jack Yu
Browse files

resolve merge conflicts of 55a9f281 to stage-aosp-master

Test: I solemnly swear I did not test this conflict resolution.
Change-Id: I1b30969134b305207e35d79a0e267d0e65533a4f
parents e06e36bf 55a9f281
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -377,18 +377,18 @@ public class SubscriptionInfoUpdater extends Handler {
    }

    private void handleSimLoaded(int slotId) {
        logd("handleSimStateLoadedInternal: slotId: " + slotId);
        logd("handleSimLoaded: slotId: " + slotId);

        // The SIM should be loaded at this state, but it is possible in cases such as SIM being
        // removed or a refresh RESET that the IccRecords could be null. The right behavior is to
        // not broadcast the SIM loaded.
        IccRecords records = mPhone[slotId].getIccCard().getIccRecords();
        if (records == null) {  // Possibly a race condition.
            logd("onRecieve: IccRecords null");
            logd("handleSimLoaded: IccRecords null");
            return;
        }
        if (records.getIccId() == null) {
            logd("onRecieve: IccID null");
            logd("handleSimLoaded: IccID null");
            return;
        }
        mIccId[slotId] = records.getIccId();
+5 −5
Original line number Diff line number Diff line
@@ -46,7 +46,6 @@ import com.android.internal.telephony.uicc.IccCardApplicationStatus.AppState;
import com.android.internal.telephony.uicc.IccCardApplicationStatus.PersoSubState;
import com.android.internal.telephony.uicc.IccCardStatus.CardState;
import com.android.internal.telephony.uicc.IccCardStatus.PinState;
import com.android.internal.telephony.uicc.UiccController;

import java.io.FileDescriptor;
import java.io.PrintWriter;
@@ -87,7 +86,7 @@ public class IccCardProxy extends Handler implements IccCard {
    private static final int EVENT_ICC_RECORD_EVENTS = 500;
    private static final int EVENT_SUBSCRIPTION_ACTIVATED = 501;
    private static final int EVENT_SUBSCRIPTION_DEACTIVATED = 502;
    private static final int EVENT_CARRIER_PRIVILIGES_LOADED = 503;
    private static final int EVENT_CARRIER_PRIVILEGES_LOADED = 503;

    private Integer mPhoneId = null;

@@ -259,7 +258,7 @@ public class IccCardProxy extends Handler implements IccCard {
                }
                if (mUiccCard != null && !mUiccCard.areCarrierPriviligeRulesLoaded()) {
                    mUiccCard.registerForCarrierPrivilegeRulesLoaded(
                        this, EVENT_CARRIER_PRIVILIGES_LOADED, null);
                            this, EVENT_CARRIER_PRIVILEGES_LOADED, null);
                } else {
                    onRecordsLoaded();
                }
@@ -295,7 +294,7 @@ public class IccCardProxy extends Handler implements IccCard {
                }
                break;

            case EVENT_CARRIER_PRIVILIGES_LOADED:
            case EVENT_CARRIER_PRIVILEGES_LOADED:
                log("EVENT_CARRIER_PRIVILEGES_LOADED");
                if (mUiccCard != null) {
                    mUiccCard.unregisterForCarrierPrivilegeRulesLoaded(this);
@@ -525,7 +524,8 @@ public class IccCardProxy extends Handler implements IccCard {
            intent.putExtra(IccCardConstants.INTENT_KEY_ICC_STATE, value);
            intent.putExtra(IccCardConstants.INTENT_KEY_LOCKED_REASON, reason);
            intent.putExtra(PhoneConstants.PHONE_KEY, mPhoneId);  // SubId may not be valid.
            log("Sending intent ACTION_INTERNAL_SIM_STATE_CHANGED" + " for mPhoneId : " + mPhoneId);
            log("Sending intent ACTION_INTERNAL_SIM_STATE_CHANGED value=" + value
                    + " for mPhoneId : " + mPhoneId);
            ActivityManager.broadcastStickyIntent(intent, UserHandle.USER_ALL);
        }
    }
+3 −3
Original line number Diff line number Diff line
@@ -94,7 +94,7 @@ public class UiccCard {
    private static final int EVENT_TRANSMIT_APDU_LOGICAL_CHANNEL_DONE = 17;
    private static final int EVENT_TRANSMIT_APDU_BASIC_CHANNEL_DONE = 18;
    private static final int EVENT_SIM_IO_DONE = 19;
    private static final int EVENT_CARRIER_PRIVILIGES_LOADED = 20;
    private static final int EVENT_CARRIER_PRIVILEGES_LOADED = 20;

    private static final LocalLog mLocalLog = new LocalLog(100);

@@ -158,7 +158,7 @@ public class UiccCard {
            log("Before privilege rules: " + mCarrierPrivilegeRules + " : " + mCardState);
            if (mCarrierPrivilegeRules == null && mCardState == CardState.CARDSTATE_PRESENT) {
                mCarrierPrivilegeRules = new UiccCarrierPrivilegeRules(this,
                        mHandler.obtainMessage(EVENT_CARRIER_PRIVILIGES_LOADED));
                        mHandler.obtainMessage(EVENT_CARRIER_PRIVILEGES_LOADED));
            } else if (mCarrierPrivilegeRules != null
                    && mCardState != CardState.CARDSTATE_PRESENT) {
                mCarrierPrivilegeRules = null;
@@ -384,7 +384,7 @@ public class UiccCard {
                    AsyncResult.forMessage((Message)ar.userObj, ar.result, ar.exception);
                    ((Message)ar.userObj).sendToTarget();
                    break;
                case EVENT_CARRIER_PRIVILIGES_LOADED:
                case EVENT_CARRIER_PRIVILEGES_LOADED:
                    onCarrierPriviligesLoadedMessage();
                    break;
                default: