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

Commit 19278b94 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Clean bluetooth code" into tm-qpr-dev

parents af96b1ea 24278d16
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -203,7 +203,7 @@ public final class Utils {
    public static String findBluetoothPackageName(Context context)
            throws NameNotFoundException {
        // this activity will always be in the package where the rest of Bluetooth lives
        String sentinelActivity = "com.android.bluetooth.opp.BluetoothOppLauncherActivity";
        final String sentinelActivity = "com.android.bluetooth.opp.BluetoothOppLauncherActivity";
        PackageManager packageManager = context.createContextAsUser(UserHandle.SYSTEM, 0)
                .getPackageManager();
        String[] allPackages = packageManager.getPackagesForUid(BLUETOOTH_UID);
+2 −4
Original line number Diff line number Diff line
@@ -41,15 +41,13 @@ public class BluetoothMaxConnectedAudioDevicesPreferenceController extends

    private int mDefaultMaxConnectedAudioDevices = 0;

    private final BluetoothManager mBluetoothManager;

    public BluetoothMaxConnectedAudioDevicesPreferenceController(Context context) {
        super(context);

        mBluetoothManager = context.getSystemService(BluetoothManager.class);
        final BluetoothManager bluetoothManager = context.getSystemService(BluetoothManager.class);

        mDefaultMaxConnectedAudioDevices =
              mBluetoothManager.getAdapter().getMaxConnectedAudioDevices();
              bluetoothManager.getAdapter().getMaxConnectedAudioDevices();
    }

    @Override