Home
last modified time | relevance | path

Searched refs:mTelephonyManager (Results 1 – 25 of 169) sorted by relevance

1234567

/packages/apps/Bluetooth/tests/unit/src/com/android/bluetooth/hfp/
DHeadsetPhoneStateTest.java55 @Mock private TelephonyManager mTelephonyManager; field in HeadsetPhoneStateTest
75 mTelephonyManager); in setUp()
76 when(mTelephonyManager.createForSubscriptionId(anyInt())).thenReturn(mTelephonyManager); in setUp()
104 verifyZeroInteractions(mTelephonyManager); in testListenForPhoneState_NoneResultsNoListen()
115 verify(mTelephonyManager).listen(any(), eq(PhoneStateListener.LISTEN_SERVICE_STATE)); in testListenForPhoneState_ServiceOnly()
116 verifyNoMoreInteractions(mTelephonyManager); in testListenForPhoneState_ServiceOnly()
129 verify(mTelephonyManager).listen(any(), eq(PhoneStateListener.LISTEN_SERVICE_STATE in testListenForPhoneState_ServiceAndSignalStrength()
131 verify(mTelephonyManager).setRadioIndicationUpdateMode( in testListenForPhoneState_ServiceAndSignalStrength()
134 verifyNoMoreInteractions(mTelephonyManager); in testListenForPhoneState_ServiceAndSignalStrength()
146 verify(mTelephonyManager).listen(any(), eq(PhoneStateListener.LISTEN_SERVICE_STATE in testListenForPhoneState_ServiceAndSignalStrengthUpdateTurnOffSignalStrengh()
[all …]
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/network/
DMobileDataTogglePreferenceControllerTest.java68 private TelephonyManager mTelephonyManager; field in MobileDataTogglePreferenceControllerTest
76 mTelephonyManager = mContext.getSystemService(TelephonyManager.class); in setUp()
77 mTelephonyManager.setDataEnabled(false); in setUp()
79 getShadowTelephonyManager().setTelephonyManagerForSubscriptionId(SUB_ID, mTelephonyManager); in setUp()
142 mTelephonyManager.setDataEnabled(true); in refreshUi_dataEnabled_setChecked()
150 mTelephonyManager.setDataEnabled(false); in refreshUi_dataDisabled_setUnchecked()
169 mTelephonyManager.setDataEnabled(true); in handlePreferenceChanged_setFalse_isMultiSim_disablesData()
173 assertThat(mTelephonyManager.isDataEnabled()).isFalse(); in handlePreferenceChanged_setFalse_isMultiSim_disablesData()
179 mTelephonyManager.setDataEnabled(true); in handlePreferenceChanged_setFalse_isMultiSim_setsUnchecked()
189 mTelephonyManager.setDataEnabled(false); in handlePreferenceChanged_setTrue_isSingleSim_enablesData()
[all …]
DRoamingPreferenceControllerTest.java68 private TelephonyManager mTelephonyManager; field in RoamingPreferenceControllerTest
78 mTelephonyManager = mContext.getSystemService(TelephonyManager.class); in setUp()
79 getShadowTelephonyManager().setTelephonyManagerForSubscriptionId(SUB_ID, mTelephonyManager); in setUp()
120 SubscriptionManager.INVALID_SUBSCRIPTION_ID, mTelephonyManager); in refreshUi_invalidSubId_isDisabled()
138 mTelephonyManager.setDataRoamingEnabled(true); in refreshUi_roamingEnabled_setChecked()
147 mTelephonyManager.setDataRoamingEnabled(false); in refreshUi_roamingDisabled_setUnchecked()
157 mTelephonyManager.setDataRoamingEnabled(true); in callChangeListener_toggleFalse_turnOffRoaming()
161 assertThat(mTelephonyManager.isDataRoamingEnabled()).isFalse(); in callChangeListener_toggleFalse_turnOffRoaming()
167 mTelephonyManager.setDataRoamingEnabled(false); in callChangeListener_toggleTrue_needsDialog_showDialog()
181 mTelephonyManager.setDataRoamingEnabled(false); in confirmDialog_turnOnRoaming()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/
DMobileDataPreferenceControllerTest.java57 private TelephonyManager mTelephonyManager; field in MobileDataPreferenceControllerTest
76 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
78 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
79 doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( in setUp()
99 doReturn(true).when(mTelephonyManager).isDataEnabled(); in isDialogNeeded_disableSingleSim_returnFalse()
102 doReturn(1).when(mTelephonyManager).getSimCount(); in isDialogNeeded_disableSingleSim_returnFalse()
109 doReturn(false).when(mTelephonyManager).isDataEnabled(); in isDialogNeeded_enableNonDefaultSimInMultiSimMode_returnTrue()
113 doReturn(2).when(mTelephonyManager).getSimCount(); in isDialogNeeded_enableNonDefaultSimInMultiSimMode_returnTrue()
131 doReturn(true).when(mTelephonyManager).isDataEnabled(); in onPreferenceChange_singleSim_On_shouldEnableData()
134 doReturn(1).when(mTelephonyManager).getSimCount(); in onPreferenceChange_singleSim_On_shouldEnableData()
[all …]
DMmsMessagePreferenceControllerTest.java51 private TelephonyManager mTelephonyManager; field in MmsMessagePreferenceControllerTest
64 when(mContext.getSystemService(TelephonyManager.class)).thenReturn(mTelephonyManager); in setUp()
65 when(mContext.getSystemService(Context.TELEPHONY_SERVICE)).thenReturn(mTelephonyManager); in setUp()
67 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
85 when(mTelephonyManager.isDataEnabled()).thenReturn(true); in getAvailabilityStatus_mobileDataOn_returnUnavailable()
92 when(mTelephonyManager.isApnMetered(ApnSetting.TYPE_MMS)).thenReturn(false); in getAvailabilityStatus_meteredOff_returnUnavailable()
100 when(mTelephonyManager.isDataEnabled()).thenReturn(false); in getAvailabilityStatus_mobileDataOffWithValidSubId_returnAvailable()
101 when(mTelephonyManager.isApnMetered(ApnSetting.TYPE_MMS)).thenReturn(true); in getAvailabilityStatus_mobileDataOffWithValidSubId_returnAvailable()
108 when(mTelephonyManager.isDataEnabledForApn(ApnSetting.TYPE_MMS)).thenReturn(false); in isChecked_returnDataFromTelephonyManager()
111 when(mTelephonyManager.isDataEnabledForApn(ApnSetting.TYPE_MMS)).thenReturn(true); in isChecked_returnDataFromTelephonyManager()
DApnPreferenceControllerTest.java56 private TelephonyManager mTelephonyManager; field in ApnPreferenceControllerTest
73 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
75 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
76 doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( in setUp()
90 doReturn(PhoneConstants.PHONE_TYPE_CDMA).when(mTelephonyManager).getPhoneType(); in getAvailabilityStatus_apnSettingsNotSupported_returnUnavailable()
100 doReturn(PhoneConstants.PHONE_TYPE_CDMA).when(mTelephonyManager).getPhoneType(); in getAvailabilityStatus_apnSettingsSupportedWithCDMA_returnAvailable()
110 doReturn(PhoneConstants.PHONE_TYPE_GSM).when(mTelephonyManager).getPhoneType(); in getAvailabilityStatus_apnSettingsSupportedWithGsm_returnAvailable()
120 doReturn(PhoneConstants.PHONE_TYPE_GSM).when(mTelephonyManager).getPhoneType(); in getAvailabilityStatus_carrierConfigNull_returnUnavailable()
129 doReturn(PhoneConstants.PHONE_TYPE_GSM).when(mTelephonyManager).getPhoneType(); in getAvailabilityStatus_hideCarrierNetworkSettings_returnUnavailable()
DMobileNetworkUtilsTest.java63 private TelephonyManager mTelephonyManager; field in MobileNetworkUtilsTest
92 when(mContext.getSystemService(Context.TELEPHONY_SERVICE)).thenReturn(mTelephonyManager); in setUp()
93 when(mTelephonyManager.createForSubscriptionId(SUB_ID_1)).thenReturn(mTelephonyManager); in setUp()
94 when(mTelephonyManager.createForSubscriptionId(SUB_ID_2)).thenReturn(mTelephonyManager2); in setUp()
115 verify(mTelephonyManager).setDataEnabled(true); in setMobileDataEnabled_setEnabled_enabled()
124 verify(mTelephonyManager, never()).setDataEnabled(anyBoolean()); in setMobileDataEnabled_setDisabled_disabled()
131 verify(mTelephonyManager).setDataEnabled(true); in setMobileDataEnabled_disableOtherSubscriptions()
160 when(mTelephonyManager.getPhoneType()).thenReturn(PhoneConstants.PHONE_TYPE_CDMA); in isCdmaOptions_phoneTypeCdma_returnTrue()
167 when(mTelephonyManager.getPhoneType()).thenReturn(PhoneConstants.PHONE_TYPE_GSM); in isCdmaOptions_worldModeWithGsmWcdma_returnTrue()
179 when(mTelephonyManager.getPhoneType()).thenReturn(PhoneConstants.PHONE_TYPE_GSM); in isCdmaOptions_carrierWorldModeWithoutHideCarrier_returnTrue()
[all …]
DVideoCallingPreferenceControllerTest.java47 private TelephonyManager mTelephonyManager; field in VideoCallingPreferenceControllerTest
63 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
64 doReturn(mTelephonyManager).when(mContext).getSystemService(TelephonyManager.class); in setUp()
66 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
82 doReturn(true).when(mTelephonyManager).isDataEnabled(); in setUp()
101 doReturn(false).when(mTelephonyManager).isDataEnabled(); in isVideoCallEnabled_dataDisabled_returnFalse()
121 doReturn(TelephonyManager.CALL_STATE_IDLE).when(mTelephonyManager).getCallState(SUB_ID); in updateState_4gLteOnWithoutCall_checked()
DDataServiceSetupPreferenceControllerTest.java60 private TelephonyManager mTelephonyManager; field in DataServiceSetupPreferenceControllerTest
76 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
77 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
78 doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( in setUp()
95 doReturn(PhoneConstants.LTE_ON_CDMA_TRUE).when(mTelephonyManager).getLteOnCdmaMode(); in getAvailabilityStatus_allConfigOn_returnAvailable()
106 doReturn(PhoneConstants.LTE_ON_CDMA_TRUE).when(mTelephonyManager).getLteOnCdmaMode(); in getAvailabilityStatus_missUrl_returnUnavailable()
118 doReturn(PhoneConstants.LTE_ON_CDMA_FALSE).when(mTelephonyManager).getLteOnCdmaMode(); in getAvailabilityStatus_notCdma_returnUnavailable()
DPreferredNetworkModePreferenceControllerTest.java52 private TelephonyManager mTelephonyManager; field in PreferredNetworkModePreferenceControllerTest
68 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
69 doReturn(mTelephonyManager).when(mContext).getSystemService(TelephonyManager.class); in setUp()
71 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
72 doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( in setUp()
118 doReturn(true).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateSuccess()
131 doReturn(false).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateFail()
DRoamingPreferenceControllerTest.java55 private TelephonyManager mTelephonyManager; field in RoamingPreferenceControllerTest
74 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
77 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
78 doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( in setUp()
107 doReturn(false).when(mTelephonyManager).isDataRoamingEnabled(); in isDialogNeeded_roamingDisabledWithoutFlag_returnTrue()
114 doReturn(true).when(mTelephonyManager).isDataRoamingEnabled(); in isDialogNeeded_roamingEnabled_returnFalse()
139 doReturn(true).when(mTelephonyManager).isDataRoamingEnabled(); in updateState_validSubId_enabled()
DEnabledNetworkModePreferenceControllerTest.java53 private TelephonyManager mTelephonyManager; field in EnabledNetworkModePreferenceControllerTest
69 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
70 doReturn(mTelephonyManager).when(mContext).getSystemService(TelephonyManager.class); in setUp()
72 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
73 doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( in setUp()
141 doReturn(true).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateSuccess()
154 doReturn(false).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateFail()
/packages/apps/Settings/src/com/android/settings/deviceinfo/imei/
DImeiInfoDialogController.java71 private final TelephonyManager mTelephonyManager; field in ImeiInfoDialogController
83 mTelephonyManager = context.getSystemService(TelephonyManager.class) in ImeiInfoDialogController()
86 mTelephonyManager = tm; in ImeiInfoDialogController()
88 mTelephonyManager = null; in ImeiInfoDialogController()
96 if (mTelephonyManager == null) { in populateImeiInfo()
100 if (mTelephonyManager.getPhoneType() == TelephonyManager.PHONE_TYPE_CDMA) { in populateImeiInfo()
112 ? mTelephonyManager.getCdmaMin(mSubscriptionInfo.getSubscriptionId()) in updateDialogForCdmaPhone()
125 getTextAsDigits(mTelephonyManager.getImei(mSlotId))); in updateDialogForCdmaPhone()
127 getTextAsDigits(mTelephonyManager.getDeviceSoftwareVersion(mSlotId))); in updateDialogForCdmaPhone()
135 mDialog.setText(ID_IMEI_VALUE, getTextAsDigits(mTelephonyManager.getImei(mSlotId))); in updateDialogForGsmPhone()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/deviceinfo/imei/
DImeiInfoPreferenceControllerTest.java66 private TelephonyManager mTelephonyManager; field in ImeiInfoPreferenceControllerTest
85 ReflectionHelpers.setField(mController, "mTelephonyManager", mTelephonyManager); in setUp()
95 when(mTelephonyManager.getPhoneCount()).thenReturn(2); in displayPreference_multiSimGsm_shouldAddSecondPreference()
96 when(mTelephonyManager.getCurrentPhoneType(anyInt())).thenReturn(PHONE_TYPE_GSM); in displayPreference_multiSimGsm_shouldAddSecondPreference()
107 when(mTelephonyManager.getCurrentPhoneType(anyInt())).thenReturn(PHONE_TYPE_CDMA); in displayPreference_singleSimCdmaPhone_shouldSetSingleSimCdmaTitleAndMeid()
108 when(mTelephonyManager.getMeid(anyInt())).thenReturn(meid); in displayPreference_singleSimCdmaPhone_shouldSetSingleSimCdmaTitleAndMeid()
120 when(mTelephonyManager.getPhoneCount()).thenReturn(2); in displayPreference_multiSimCdmaPhone_shouldSetMultiSimCdmaTitleAndMeid()
121 when(mTelephonyManager.getCurrentPhoneType(anyInt())).thenReturn(PHONE_TYPE_CDMA); in displayPreference_multiSimCdmaPhone_shouldSetMultiSimCdmaTitleAndMeid()
122 when(mTelephonyManager.getMeid(anyInt())).thenReturn(meid); in displayPreference_multiSimCdmaPhone_shouldSetMultiSimCdmaTitleAndMeid()
137 when(mTelephonyManager.getCurrentPhoneType(anyInt())).thenReturn(PHONE_TYPE_GSM); in displayPreference_singleSimGsmPhone_shouldSetSingleSimGsmTitleAndImei()
[all …]
DImeiInfoDialogControllerTest.java67 private TelephonyManager mTelephonyManager; field in ImeiInfoDialogControllerTest
84 stm.setTelephonyManagerForSubscriptionId(SUB_ID, mTelephonyManager); in setup()
89 when(mTelephonyManager.getCdmaPrlVersion()).thenReturn(PRL_VERSION); in setup()
90 when(mTelephonyManager.getMeid(anyInt())).thenReturn(MEID_NUMBER); in setup()
91 when(mTelephonyManager.getCdmaMin(anyInt())).thenReturn(MIN_NUMBER); in setup()
92 when(mTelephonyManager.getDeviceSoftwareVersion(anyInt())).thenReturn(IMEI_SV_NUMBER); in setup()
93 when(mTelephonyManager.getImei(anyInt())).thenReturn(IMEI_NUMBER); in setup()
108 when(mTelephonyManager.getPhoneType()).thenReturn(TelephonyManager.PHONE_TYPE_CDMA); in populateImeiInfo_cdmaLteEnabled_shouldSetMeidAndImeiAndMin()
122 when(mTelephonyManager.getPhoneType()).thenReturn(TelephonyManager.PHONE_TYPE_CDMA); in populateImeiInfo_cdmaLteDisabled_shouldSetMeidAndMinAndRemoveGsmSettings()
135 when(mTelephonyManager.getPhoneType()).thenReturn(TelephonyManager.PHONE_TYPE_CDMA); in populateImeiInfo_cdmaSimDisabled_shouldRemoveImeiInfoAndSetMinPrlToEmpty()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/deviceinfo/imei/
DImeiInfoDialogController.java70 private final TelephonyManager mTelephonyManager; field in ImeiInfoDialogController
78 mTelephonyManager = (TelephonyManager) context.getSystemService( in ImeiInfoDialogController()
87 if (mTelephonyManager.getPhoneType() == TelephonyManager.PHONE_TYPE_CDMA) { in populateImeiInfo()
98 mSubscriptionInfo != null ? mTelephonyManager.getCdmaMin( in updateDialogForCdmaPhone()
111 getTextAsDigits(mTelephonyManager.getImei(mSlotId))); in updateDialogForCdmaPhone()
113 getTextAsDigits(mTelephonyManager.getDeviceSoftwareVersion(mSlotId))); in updateDialogForCdmaPhone()
121 mDialog.setText(ID_IMEI_VALUE, getTextAsDigits(mTelephonyManager.getImei(mSlotId))); in updateDialogForGsmPhone()
123 getTextAsDigits(mTelephonyManager.getDeviceSoftwareVersion(mSlotId))); in updateDialogForGsmPhone()
140 return mTelephonyManager.getCdmaPrlVersion(); in getCdmaPrlVersion()
145 return mTelephonyManager.getLteOnCdmaMode(mSubscriptionInfo.getSubscriptionId()) in isCdmaLteEnabled()
[all …]
DImeiInfoPreferenceController.java44 private final TelephonyManager mTelephonyManager; field in ImeiInfoPreferenceController
50 mTelephonyManager = (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE); in ImeiInfoPreferenceController()
51 mIsMultiSim = mTelephonyManager.getPhoneCount() > 1; in ImeiInfoPreferenceController()
68 for (int simSlotNumber = 1; simSlotNumber < mTelephonyManager.getPhoneCount(); in displayPreference()
81 final int phoneType = mTelephonyManager.getPhoneType(); in getSummary()
82 return phoneType == PHONE_TYPE_CDMA ? mTelephonyManager.getMeid() in getSummary()
83 : mTelephonyManager.getImei(); in getSummary()
124 final int phoneType = mTelephonyManager.getPhoneType(); in updatePreference()
131 preference.setSummary(mTelephonyManager.getImei(simSlot)); in updatePreference()
147 return mTelephonyManager.getMeid(simSlot); in getMeid()
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/gsm/
DAutoSelectPreferenceControllerTest.java53 private TelephonyManager mTelephonyManager; field in AutoSelectPreferenceControllerTest
71 when(mContext.getSystemService(Context.TELEPHONY_SERVICE)).thenReturn(mTelephonyManager); in setUp()
75 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
91 when(mTelephonyManager.getNetworkSelectionMode()).thenReturn( in setChecked_isChecked_showProgressDialog()
98 verify(mTelephonyManager).setNetworkSelectionModeAutomatic(); in setChecked_isChecked_showProgressDialog()
103 when(mTelephonyManager.getServiceState().getRoaming()).thenReturn(true); in updateState_isRoaming_enabled()
112 when(mTelephonyManager.getServiceState().getRoaming()).thenReturn(false); in updateState_notRoamingWithAutoSelectOn_disabled()
113 doReturn(OPERATOR_NAME).when(mTelephonyManager).getSimOperatorName(); in updateState_notRoamingWithAutoSelectOn_disabled()
120 mTelephonyManager.getSimOperatorName())); in updateState_notRoamingWithAutoSelectOn_disabled()
DOpenNetworkSelectPagePreferenceControllerTest.java50 private TelephonyManager mTelephonyManager; field in OpenNetworkSelectPagePreferenceControllerTest
68 when(mContext.getSystemService(Context.TELEPHONY_SERVICE)).thenReturn(mTelephonyManager); in setUp()
72 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
73 when(mTelephonyManager.getServiceState()).thenReturn(mServiceState); in setUp()
86 when(mTelephonyManager.getNetworkSelectionMode()).thenReturn( in updateState_modeAuto_disabled()
97 doReturn(OPERATOR_NAME).when(mTelephonyManager).getNetworkOperatorName(); in getSummary_inService_returnOperatorName()
105 doReturn(OPERATOR_NAME).when(mTelephonyManager).getNetworkOperatorName(); in getSummary_notInService_returnDisconnect()
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/cdma/
DCdmaSystemSelectPreferenceControllerTest.java51 private TelephonyManager mTelephonyManager; field in CdmaSystemSelectPreferenceControllerTest
69 doReturn(mTelephonyManager).when(mContext).getSystemService(Context.TELEPHONY_SERVICE); in setUp()
71 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
72 doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( in setUp()
93 doReturn(true).when(mTelephonyManager).setCdmaRoamingMode(anyInt()); in onPreferenceChange_selectHome_returnHomeMode()
107 mTelephonyManager).getCdmaRoamingMode(); in updateState_stateHome_displayHome()
118 mTelephonyManager).getCdmaRoamingMode(); in updateState_LteGSMWcdma_disabled()
134 mTelephonyManager).getCdmaRoamingMode(); in updateState_stateOther_resetToDefault()
/packages/services/Telephony/src/com/android/phone/
DMobileNetworkSettings.java397 private TelephonyManager mTelephonyManager; field in MobileNetworkSettings.MobileNetworkFragment
463 mTelephonyManager.listen(this, PhoneStateListener.LISTEN_NONE); in updateSubscriptionId()
468 mTelephonyManager.listen(this, PhoneStateListener.LISTEN_CALL_STATE); in updateSubscriptionId()
477 mTelephonyManager.setDataRoamingEnabled(true); in onPositiveButtonClick()
515 if (mTelephonyManager.getEmergencyCallbackMode()) { in onPreferenceTreeClick()
538 String imsi = mTelephonyManager.getSubscriberId(); in onPreferenceTreeClick()
735 mTelephonyManager = new TelephonyManager(getContext(), mSubId); in updatePhone()
794 mTelephonyManager = (TelephonyManager) activity.getSystemService( in onCreate()
936 mButtonDataRoam.setChecked(mTelephonyManager.isDataRoamingEnabled()); in onResume()
943 mTelephonyManager.createForSubscriptionId(mSubId) in onResume()
[all …]
/packages/apps/Settings/src/com/android/settings/deviceinfo/simstatus/
DSimStatusDialogController.java114 private final TelephonyManager mTelephonyManager; field in SimStatusDialogController
149 mTelephonyManager = mContext.getSystemService(TelephonyManager.class); in SimStatusDialogController()
188 mTelephonyManager.createForSubscriptionId(mSubscriptionInfo.getSubscriptionId()) in onResume()
214 mTelephonyManager.createForSubscriptionId(mSubscriptionInfo.getSubscriptionId()) in onPause()
262 && mTelephonyManager.getPhoneType() != TelephonyManager.PHONE_TYPE_CDMA; in updateLatestAreaInfo()
347 final int actualDataNetworkType = mTelephonyManager.getDataNetworkType(subId); in updateNetworkType()
348 final int actualVoiceNetworkType = mTelephonyManager.getVoiceNetworkType(subId); in updateNetworkType()
350 dataNetworkTypeName = mTelephonyManager.getNetworkTypeName(actualDataNetworkType); in updateNetworkType()
353 voiceNetworkTypeName = mTelephonyManager.getNetworkTypeName(actualVoiceNetworkType); in updateNetworkType()
417 final boolean isImsRegistered = mTelephonyManager.isImsRegistered(subscriptionId); in updateImsRegistrationState()
[all …]
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/deviceinfo/simstatus/
DSimStatusDialogController.java103 private final TelephonyManager mTelephonyManager; field in SimStatusDialogController
137 mTelephonyManager = (TelephonyManager) mContext.getSystemService( in SimStatusDialogController()
177 mTelephonyManager.createForSubscriptionId(mSubscriptionInfo.getSubscriptionId()) in onResume()
201 mTelephonyManager.createForSubscriptionId(mSubscriptionInfo.getSubscriptionId()) in onPause()
247 && mTelephonyManager.getPhoneType() != TelephonyManager.PHONE_TYPE_CDMA; in updateLatestAreaInfo()
329 final int actualDataNetworkType = mTelephonyManager.getDataNetworkType(subId); in updateNetworkType()
330 final int actualVoiceNetworkType = mTelephonyManager.getVoiceNetworkType(subId); in updateNetworkType()
332 dataNetworkTypeName = mTelephonyManager.getNetworkTypeName(actualDataNetworkType); in updateNetworkType()
335 voiceNetworkTypeName = mTelephonyManager.getNetworkTypeName(actualVoiceNetworkType); in updateNetworkType()
399 final boolean isImsRegistered = mTelephonyManager.isImsRegistered(subscriptionId); in updateImsRegistrationState()
[all …]
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/
DVibrateWhenRingPreferenceControllerTest.java65 private TelephonyManager mTelephonyManager; field in VibrateWhenRingPreferenceControllerTest
74 when(mContext.getSystemService(Context.TELEPHONY_SERVICE)).thenReturn(mTelephonyManager); in setUp()
83 when(mTelephonyManager.isVoiceCapable()).thenReturn(true); in display_shouldDisplay()
91 when(mTelephonyManager.isVoiceCapable()).thenReturn(false); in display_shouldNotDisplay_notVoiceCapable()
99 when(mTelephonyManager.isVoiceCapable()).thenReturn(true); in display_shouldNotDisplay_RampingRingerEnabled()
107 when(mTelephonyManager.isVoiceCapable()).thenReturn(true); in display_shouldNotDisplay_VoiceEnabled_RampingRingerEnabled()
115 when(mTelephonyManager.isVoiceCapable()).thenReturn(false); in display_shouldNotDisplay_VoiceDisabled_RampingRingerEnabled()
141 when(mTelephonyManager.isVoiceCapable()).thenReturn(true); in voiceCapable_availabled()
148 when(mTelephonyManager.isVoiceCapable()).thenReturn(false); in voiceCapable_notAvailabled()
/packages/apps/Settings/src/com/android/settings/network/telephony/gsm/
DAutoSelectPreferenceController.java55 private TelephonyManager mTelephonyManager; field in AutoSelectPreferenceController
65 mTelephonyManager = context.getSystemService(TelephonyManager.class); in AutoSelectPreferenceController()
86 return mTelephonyManager.getNetworkSelectionMode() in isChecked()
95 if (mTelephonyManager.getServiceState().getRoaming()) { in updateState()
102 mTelephonyManager.getSimOperatorName())); in updateState()
115 mTelephonyManager.setNetworkSelectionModeAutomatic(); in setChecked()
116 final int mode = mTelephonyManager.getNetworkSelectionMode(); in setChecked()
147 mTelephonyManager = TelephonyManager.from(mContext).createForSubscriptionId(mSubId); in init()

1234567