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

Commit 099783b9 authored by Sarah Chin's avatar Sarah Chin Committed by Automerger Merge Worker
Browse files

Merge changes from topics "displayinfocontroller", "remove_displayinfo" into rvc-dev am: a53c2a00

Change-Id: I8c5e659972118f02749a0a8eca072c1302a68d3a
parents 11ef265c a53c2a00
Loading
Loading
Loading
Loading
+9 −9
Original line number Diff line number Diff line
@@ -264,8 +264,16 @@ public class GsmCdmaPhone extends Phone {
                this, this.mCi);
        mDataEnabledSettings = mTelephonyComponentFactory
                .inject(DataEnabledSettings.class.getName()).makeDataEnabledSettings(this);
        mDeviceStateMonitor = mTelephonyComponentFactory.inject(DeviceStateMonitor.class.getName())
                .makeDeviceStateMonitor(this);

        // DisplayInfoController creates an OverrideNetworkTypeController, which uses
        // DeviceStateMonitor so needs to be crated after it is instantiated.
        mDisplayInfoController = mTelephonyComponentFactory.inject(
                DisplayInfoController.class.getName()).makeDisplayInfoController(this);

        // DcTracker uses SST so needs to be created after it is instantiated
        // DcTracker uses ServiceStateTracker and DisplayInfoController so needs to be created
        // after they are instantiated
        for (int transport : mTransportManager.getAvailableTransports()) {
            mDcTrackers.put(transport, mTelephonyComponentFactory.inject(DcTracker.class.getName())
                    .makeDcTracker(this, transport));
@@ -279,14 +287,6 @@ public class GsmCdmaPhone extends Phone {
                EVENT_SET_CARRIER_DATA_ENABLED, null, false);

        mSST.registerForNetworkAttached(this, EVENT_REGISTERED_TO_NETWORK, null);
        mDeviceStateMonitor = mTelephonyComponentFactory.inject(DeviceStateMonitor.class.getName())
                .makeDeviceStateMonitor(this);

        // DisplayInfoController creates an OverrideNetworkTypeController, which uses
        // DeviceStateMonitor so needs to be crated after it is instantiated.
        mDisplayInfoController = mTelephonyComponentFactory.inject(
                DisplayInfoController.class.getName()).makeDisplayInfoController(this);

        mSST.registerForVoiceRegStateOrRatChanged(this, EVENT_VRS_OR_RAT_CHANGED, null);

        mSettingsObserver = new SettingsObserver(context, this);
+9 −14
Original line number Diff line number Diff line
@@ -2006,15 +2006,6 @@ public class ServiceStateTracker extends Handler {
        return cdmaRoaming && !isSameOperatorNameFromSimAndSS(s);
    }

    private boolean isNrStateChanged(
            NetworkRegistrationInfo oldRegState, NetworkRegistrationInfo newRegState) {
        if (oldRegState == null || newRegState == null) {
            return oldRegState != newRegState;
        }

        return oldRegState.getNrState() != newRegState.getNrState();
    }

    private boolean updateNrFrequencyRangeFromPhysicalChannelConfigs(
            List<PhysicalChannelConfig> physicalChannelConfigs, ServiceState ss) {
        int newFrequencyRange = ServiceState.FREQUENCY_RANGE_UNKNOWN;
@@ -3261,11 +3252,7 @@ public class ServiceStateTracker extends Handler {
        boolean hasNrFrequencyRangeChanged =
                mSS.getNrFrequencyRange() != mNewSS.getNrFrequencyRange();

        boolean hasNrStateChanged = isNrStateChanged(
                mSS.getNetworkRegistrationInfo(
                        NetworkRegistrationInfo.DOMAIN_PS, AccessNetworkType.EUTRAN),
                mNewSS.getNetworkRegistrationInfo(
                        NetworkRegistrationInfo.DOMAIN_PS, AccessNetworkType.EUTRAN));
        boolean hasNrStateChanged = mSS.getNrState() != mNewSS.getNrState();

        final List<CellIdentity> prioritizedCids = getPrioritizedCellIdentities(mNewSS);

@@ -3582,6 +3569,14 @@ public class ServiceStateTracker extends Handler {
            mPhone.notifyLocationChanged(getCellIdentity());
        }

        if (hasNrStateChanged) {
            mNrStateChangedRegistrants.notifyRegistrants();
        }

        if (hasNrFrequencyRangeChanged) {
            mNrFrequencyChangedRegistrants.notifyRegistrants();
        }

        if (mPhone.isPhoneTypeGsm()) {
            if (!isGprsConsistent(mSS.getDataRegistrationState(), mSS.getState())) {
                if (!mStartedGprsRegCheck && !mReportedGprsNoReg) {
+41 −238

File changed.

Preview size limit exceeded, changes collapsed.

+31 −211

File changed.

Preview size limit exceeded, changes collapsed.