Loading android/blueberry/server/src/com/android/blueberry/Host.kt +1 −1 Original line number Diff line number Diff line Loading @@ -76,7 +76,7 @@ class Host(private val context: Context, private val server: Server) : HostImplB grpcUnary<Empty>(scope, responseObserver) { Log.i(TAG, "reset") bluetoothAdapter.factoryReset() bluetoothAdapter.clearBluetooth() val stateFlow = flow.filter { it.getAction() == BluetoothAdapter.ACTION_STATE_CHANGED }.map { Loading framework/api/system-current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -54,11 +54,11 @@ package android.bluetooth { public final class BluetoothAdapter { method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean addOnMetadataChangedListener(@NonNull android.bluetooth.BluetoothDevice, @NonNull java.util.concurrent.Executor, @NonNull android.bluetooth.BluetoothAdapter.OnMetadataChangedListener); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean clearBluetooth(); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean disable(boolean); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public boolean disableBLE(); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public boolean enableBLE(); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public boolean enableNoAutoConnect(); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean factoryReset(); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public void generateLocalOobData(int, @NonNull java.util.concurrent.Executor, @NonNull android.bluetooth.BluetoothAdapter.OobDataCallback); method @NonNull @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public java.util.List<android.bluetooth.BluetoothDevice> getActiveDevices(int); method public int getConnectionState(); Loading framework/java/android/bluetooth/BluetoothAdapter.java +17 −1 Original line number Diff line number Diff line Loading @@ -1412,7 +1412,7 @@ public final class BluetoothAdapter { android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED, }) public boolean factoryReset() { public boolean clearBluetooth() { try { mServiceLock.readLock().lock(); if (mService != null) { Loading @@ -1434,6 +1434,22 @@ public final class BluetoothAdapter { return false; } /** * See {@link #clearBluetooth()} * * @return true to indicate that the config file was successfully cleared * @hide */ @UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553) @RequiresBluetoothConnectPermission @RequiresPermission(allOf = { android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED, }) public boolean factoryReset() { return clearBluetooth(); } /** * Get the UUIDs supported by the local Bluetooth adapter. * Loading Loading
android/blueberry/server/src/com/android/blueberry/Host.kt +1 −1 Original line number Diff line number Diff line Loading @@ -76,7 +76,7 @@ class Host(private val context: Context, private val server: Server) : HostImplB grpcUnary<Empty>(scope, responseObserver) { Log.i(TAG, "reset") bluetoothAdapter.factoryReset() bluetoothAdapter.clearBluetooth() val stateFlow = flow.filter { it.getAction() == BluetoothAdapter.ACTION_STATE_CHANGED }.map { Loading
framework/api/system-current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -54,11 +54,11 @@ package android.bluetooth { public final class BluetoothAdapter { method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean addOnMetadataChangedListener(@NonNull android.bluetooth.BluetoothDevice, @NonNull java.util.concurrent.Executor, @NonNull android.bluetooth.BluetoothAdapter.OnMetadataChangedListener); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean clearBluetooth(); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean disable(boolean); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public boolean disableBLE(); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public boolean enableBLE(); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public boolean enableNoAutoConnect(); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public boolean factoryReset(); method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public void generateLocalOobData(int, @NonNull java.util.concurrent.Executor, @NonNull android.bluetooth.BluetoothAdapter.OobDataCallback); method @NonNull @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED}) public java.util.List<android.bluetooth.BluetoothDevice> getActiveDevices(int); method public int getConnectionState(); Loading
framework/java/android/bluetooth/BluetoothAdapter.java +17 −1 Original line number Diff line number Diff line Loading @@ -1412,7 +1412,7 @@ public final class BluetoothAdapter { android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED, }) public boolean factoryReset() { public boolean clearBluetooth() { try { mServiceLock.readLock().lock(); if (mService != null) { Loading @@ -1434,6 +1434,22 @@ public final class BluetoothAdapter { return false; } /** * See {@link #clearBluetooth()} * * @return true to indicate that the config file was successfully cleared * @hide */ @UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553) @RequiresBluetoothConnectPermission @RequiresPermission(allOf = { android.Manifest.permission.BLUETOOTH_CONNECT, android.Manifest.permission.BLUETOOTH_PRIVILEGED, }) public boolean factoryReset() { return clearBluetooth(); } /** * Get the UUIDs supported by the local Bluetooth adapter. * Loading