/packages/apps/Nfc/tests/instrumentation/src/com/android/nfc/ |
D | NfcStateTest.java | 76 mState = NfcAdapter.STATE_OFF; in setUp() 104 wait_for_state(NfcAdapter.STATE_OFF); in testSetControllerAlwaysOnTrueFromFalseWhenDisabled() 121 wait_for_state(NfcAdapter.STATE_OFF); in testSetControllerAlwaysOnFalseFromTrueWhenDisabled() 138 wait_for_state(NfcAdapter.STATE_OFF); in testSetControllerAlwaysOnFalseFromFalseWhenDisabled() 155 wait_for_state(NfcAdapter.STATE_OFF); in testSetControllerAlwaysOnTrueFromTrueWhenDisabled() 240 wait_for_state(NfcAdapter.STATE_OFF); in testEnableWhenSetControllerAlwaysOnTrueAndDisabled() 263 wait_for_state(NfcAdapter.STATE_OFF); in testDisableWhenSetControllerAlwaysOnTrueAndEnabled() 264 assertThat(mState).isEqualTo(NfcAdapter.STATE_OFF); in testDisableWhenSetControllerAlwaysOnTrueAndEnabled() 276 wait_for_state(NfcAdapter.STATE_OFF); in testDisableWhenEnabled() 277 assertThat(mState).isEqualTo(NfcAdapter.STATE_OFF); in testDisableWhenEnabled() [all …]
|
/packages/modules/Bluetooth/framework/tests/util/src/ |
D | BlockingBluetoothAdapter.kt | 23 import android.bluetooth.BluetoothAdapter.STATE_OFF 72 if (!state.eq(STATE_OFF)) { in enableBLE() 110 return state.waitForStateWithTimeout(stateChangeTimeout, STATE_OFF) in disableBLE() 135 if (state.eq(STATE_OFF)) { in disable() 150 return state.waitForStateWithTimeout(stateChangeTimeout, STATE_OFF) in disable() 183 if (state != STATE_OFF) { in get() 188 STATE_OFF in get() 204 STATE_OFF -> "OFF" in nameForState()
|
/packages/modules/Bluetooth/android/app/tests/unit/src/com/android/bluetooth/btservice/ |
D | ProfileServiceTest.java | 188 setAllProfilesState(BluetoothAdapter.STATE_OFF, 1); in testEnableDisable() 197 setAllProfilesState(BluetoothAdapter.STATE_OFF, 1); in testEnableDisableTwice() 199 setAllProfilesState(BluetoothAdapter.STATE_OFF, 2); in testEnableDisableTwice() 216 setProfileState(profile, BluetoothAdapter.STATE_OFF); in testEnableDisableInterleaved() 223 .onProfileServiceStateChanged(stops.capture(), eq(BluetoothAdapter.STATE_OFF)); in testEnableDisableInterleaved() 249 setProfileState(profile, BluetoothAdapter.STATE_OFF); in testRepeatedEnableDisableSingly() 253 stop.capture(), eq(BluetoothAdapter.STATE_OFF)); in testRepeatedEnableDisableSingly() 274 setProfileState(profile, BluetoothAdapter.STATE_OFF); in testProfileServiceRegisterUnregister() 290 setAllProfilesState(BluetoothAdapter.STATE_OFF, 0); in testDisable()
|
D | AdapterServiceTest.java | 22 import static android.bluetooth.BluetoothAdapter.STATE_OFF; 411 verifyStateChange(callback, STATE_OFF, STATE_BLE_TURNING_ON); in offToBleOn() 442 adapter.onProfileServiceStateChanged(service, STATE_OFF); in onToBleOn() 480 assertThat(adapter.getState()).isEqualTo(STATE_OFF); in doEnable() 554 verifyStateChange(callback, STATE_BLE_TURNING_OFF, STATE_OFF); in doDisable() 556 assertThat(adapter.getState()).isEqualTo(STATE_OFF); in doDisable() 618 assertThat(mAdapterService.getState()).isEqualTo(STATE_OFF); in testGattStartTimeout() 625 verifyStateChange(STATE_OFF, STATE_BLE_TURNING_ON); in testGattStartTimeout() 646 verifyStateChange(STATE_BLE_TURNING_OFF, STATE_OFF); in testGattStartTimeout() 647 assertThat(mAdapterService.getState()).isEqualTo(STATE_OFF); in testGattStartTimeout() [all …]
|
/packages/services/Car/car-lib/src/android/car/hardware/property/ |
D | VehicleLightState.java | 38 public static final int STATE_OFF = 0; field in VehicleLightState 59 case STATE_OFF: in toString() 71 @IntDef({STATE_OFF, STATE_ON, STATE_DAYTIME_RUNNING})
|
D | VehicleLightSwitch.java | 42 public static final int STATE_OFF = 0; field in VehicleLightSwitch 69 case STATE_OFF: in toString() 83 @IntDef({STATE_OFF, STATE_ON, STATE_DAYTIME_RUNNING, STATE_AUTOMATIC})
|
/packages/modules/Bluetooth/service/src/com/android/server/bluetooth/ |
D | BluetoothManagerService.java | 22 import static android.bluetooth.BluetoothAdapter.STATE_OFF; 345 } else if (state != STATE_ON && state != STATE_OFF && state != STATE_BLE_ON) { in estimateBusyTime() 510 } else if (!shouldBluetoothBeOn(isSatelliteModeOn) && currentState != STATE_OFF) { in handleSatelliteModeChanged() 699 if (mState.oneOf(STATE_OFF, STATE_BLE_TURNING_OFF)) { in onBleScanDisabled() 1063 if (mState.oneOf(STATE_OFF)) { in disableBle() 1573 if (!mState.oneOf(STATE_OFF)) { in handleMessage() 1706 STATE_OFF, in handleMessage() 1728 && (newState == STATE_OFF) in handleMessage() 1742 if (prevState == STATE_BLE_TURNING_OFF && newState == STATE_OFF) { in handleMessage() 1745 waitForState(STATE_OFF); in handleMessage() [all …]
|
/packages/modules/Bluetooth/service/src/ |
D | AdapterState.kt | 19 import android.bluetooth.BluetoothAdapter.STATE_OFF 34 set(STATE_OFF)
|
D | AdapterStateTest.kt | 18 import android.bluetooth.BluetoothAdapter.STATE_OFF 51 assertThat(mState.get()).isEqualTo(STATE_OFF) in init_isStateOff()
|
/packages/apps/Settings/src/com/android/settings/bluetooth/ |
D | RequestPermissionActivity.java | 99 case BluetoothAdapter.STATE_OFF: in onCreate() 126 case BluetoothAdapter.STATE_OFF: in onCreate() 228 if (mBluetoothAdapter.getState() == BluetoothAdapter.STATE_OFF) { in onDisableConfirmed() 411 if (currentState == BluetoothAdapter.STATE_OFF) { in onReceive()
|
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/bluetooth/ |
D | BluetoothPreferenceControllerTest.java | 176 getShadowBluetoothAdapter().setState(BluetoothAdapter.STATE_OFF); in getAvailabilityStatus_adapterDisabled_conditionallyUnavailable() 187 getShadowBluetoothAdapter().setState(BluetoothAdapter.STATE_OFF); in getAvailabilityStatus_adapterDisabled_conditionallyUnavailable_zoneWrite() 198 getShadowBluetoothAdapter().setState(BluetoothAdapter.STATE_OFF); in getAvailabilityStatus_adapterDisabled_conditionallyUnavailable_zoneRead() 209 getShadowBluetoothAdapter().setState(BluetoothAdapter.STATE_OFF); in getAvailabilityStatus_adapterDisabled_conditionallyUnavailable_zoneHidden()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/bluetooth/ |
D | RequestPermissionActivityTest.kt | 51 bluetoothAdapter.setState(BluetoothAdapter.STATE_OFF) in requestEnable_whenBluetoothIsOff_showConfirmDialog() 73 bluetoothAdapter.setState(BluetoothAdapter.STATE_OFF) in requestDisable_whenBluetoothIsOff_doNothing()
|
D | BluetoothEnablerTest.java | 205 mShadowBluetoothAdapter.setState(BluetoothAdapter.STATE_OFF); in startWithBluetoothOff_switchIsOff() 238 off.putExtra(BluetoothAdapter.EXTRA_STATE, BluetoothAdapter.STATE_OFF); in bluetoothTurnsOff_switchTurnsOff() 251 mShadowBluetoothAdapter.setState(BluetoothAdapter.STATE_OFF); in bluetoothTurnsOn_switchTurnsOn()
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/bluetooth/ |
D | FastPairProviderTest.java | 177 when(mMockBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in setUp() 436 sendAdapterStateChange(BluetoothAdapter.STATE_TURNING_ON, BluetoothAdapter.STATE_OFF); in testReceiveAdapterOn_startGattService() 445 sendAdapterStateChange(BluetoothAdapter.STATE_OFF, BluetoothAdapter.STATE_TURNING_OFF); in testReceiveAdapterOff_stopGattServer() 473 sendAdapterStateChange(BluetoothAdapter.STATE_TURNING_ON, BluetoothAdapter.STATE_OFF); in testReceiveScanModeConnectableAdapterOn_advertiseAccountKeyFilter() 498 sendAdapterStateChange(BluetoothAdapter.STATE_TURNING_ON, BluetoothAdapter.STATE_OFF); in testReceiveScanModeNoneAdapterOn_advertisingAccountKeyFilter()
|
D | BluetoothDeviceManagerTest.java | 212 when(mMockBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in setPreconditionsAndStart() 217 when(mMockBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in setPreconditionsAndStart() 361 sendAdapterStateChanged(BluetoothAdapter.STATE_OFF); in testNoDevicesCommit_commitEmptyDeviceString() 378 sendAdapterStateChanged(BluetoothAdapter.STATE_OFF); in testSeveralDevicesCommit_commitAllDeviceString() 984 sendAdapterStateChanged(BluetoothAdapter.STATE_OFF); in testReceiveAdapterOff_cancelAndCommit()
|
/packages/apps/Car/Settings/src/com/android/car/settings/bluetooth/ |
D | BluetoothRequestPermissionActivity.java | 117 case BluetoothAdapter.STATE_OFF: in onCreate() 136 case BluetoothAdapter.STATE_OFF: in onCreate() 153 case BluetoothAdapter.STATE_OFF: in onCreate() 432 int desiredState = BluetoothAdapter.STATE_OFF; in onConfirmDisableBluetooth()
|
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/bluetooth/ |
D | BluetoothRequestPermissionActivityTest.java | 224 when(mMockLocalBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in onCreate_bluetoothOff_requestDisableIntent_noDialog() 245 when(mMockLocalBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in onCreate_bluetoothOff_requestDiscoverableIntent_startsDialog() 267 when(mMockLocalBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in onCreate_bluetoothOff_requestEnableIntent_startsDialog() 317 when(mMockLocalBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in onPositiveClick_enableDialog_enables()
|
D | BluetoothStateSwitchPreferenceControllerTest.java | 306 mPreferenceController.handleStateChanged(BluetoothAdapter.STATE_OFF); in stateChanged_off_setsSwitchUnchecked() 315 mPreferenceController.handleStateChanged(BluetoothAdapter.STATE_OFF); in stateChanged_off_setsSwitchEnabled() 336 mPreferenceController.handleStateChanged(BluetoothAdapter.STATE_OFF); in stateChanged_off_userRestricted_setsSwitchDisabled()
|
/packages/apps/Nfc/testutils/src/com/android/nfc/utils/ |
D | NfcSnippet.java | 91 int expectedState = enable ? NfcAdapter.STATE_ON : NfcAdapter.STATE_OFF; in setNfcState() 103 NfcAdapter.STATE_OFF); in setNfcState()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/nfc/ |
D | NfcPreferenceControllerTest.java | 109 mShadowNfcAdapter.setAdapterState(NfcAdapter.STATE_OFF); in isNfcEnable_nfcStateNotTurning_shouldReturnTrue() 140 mShadowNfcAdapter.setAdapterState(NfcAdapter.STATE_OFF); in isNfcChecked_nfcStateOff_shouldReturnFalse() 247 triggerIntent.putExtra(NfcAdapter.EXTRA_ADAPTER_STATE, NfcAdapter.STATE_OFF); in ncfSliceWorker_nfcBroadcast_nfcOff_sliceUpdates()
|
/packages/services/Car/service/src/com/android/car/systemui/keyguard/ |
D | ExperimentalCarKeyguardService.java | 325 if (oldState == Display.STATE_OFF && newState != Display.STATE_OFF) { in handleDisplayChanged() 328 } else if (oldState != Display.STATE_OFF && newState == Display.STATE_OFF) { in handleDisplayChanged()
|
/packages/apps/Nfc/src/com/android/nfc/ |
D | NfcService.java | 566 || (!flag && mState != NfcAdapter.STATE_OFF)) { in setPowerSavingMode() 727 mState = NfcAdapter.STATE_OFF; in NfcService() 728 mAlwaysOnState = NfcAdapter.STATE_OFF; in NfcService() 1270 mAlwaysOnState = NfcAdapter.STATE_OFF; in enableInternal() 1274 updateState(NfcAdapter.STATE_OFF); in enableInternal() 1282 updateState(NfcAdapter.STATE_OFF); in enableInternal() 1373 if (mState == NfcAdapter.STATE_OFF) { in disableInternal() 1420 || (mAlwaysOnState == NfcAdapter.STATE_OFF) in disableInternal() 1434 updateState(NfcAdapter.STATE_OFF); in disableInternal() 1456 } else if (mState == NfcAdapter.STATE_OFF) { in enableAlwaysOnInternal() [all …]
|
/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/qc/ |
D | BluetoothSwitchTest.java | 138 when(mBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in getQCItem_bluetoothOff_switchUnchecked() 164 when(mBluetoothAdapter.getState()).thenReturn(BluetoothAdapter.STATE_OFF); in onNotifyChange_enable_enablesBluetooth()
|
/packages/modules/Bluetooth/android/app/src/com/android/bluetooth/btservice/ |
D | AdapterState.java | 78 private int mPrevState = BluetoothAdapter.STATE_OFF; 170 return BluetoothAdapter.STATE_OFF; in getStateValue()
|
/packages/apps/Settings/src/com/android/settings/nfc/ |
D | NfcEnabler.java | 39 case NfcAdapter.STATE_OFF: in handleNfcStateChanged()
|