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

Commit 99d955e5 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "[le audio] Fix leaudio test app register receiver crash" am: 9785755e am: 7cafcfad

parents 1cc22a69 7cafcfad
Loading
Loading
Loading
Loading
+10 −5
Original line number Diff line number Diff line
@@ -511,11 +511,13 @@ public class BluetoothProxy {

        adapterIntentFilter = new IntentFilter();
        adapterIntentFilter.addAction(BluetoothAdapter.ACTION_STATE_CHANGED);
        application.registerReceiver(adapterIntentReceiver, adapterIntentFilter);
        application.registerReceiver(adapterIntentReceiver, adapterIntentFilter,
                Context.RECEIVER_EXPORTED);

        bassIntentFilter = new IntentFilter();
        bassIntentFilter.addAction(BluetoothLeBroadcastAssistant.ACTION_CONNECTION_STATE_CHANGED);
        application.registerReceiver(bassIntentReceiver, bassIntentFilter);
        application.registerReceiver(bassIntentReceiver, bassIntentFilter,
                Context.RECEIVER_EXPORTED);
    }

    // Lazy constructing Singleton acquire method
@@ -742,7 +744,8 @@ public class BluetoothProxy {

        intentFilter = new IntentFilter();
        intentFilter.addAction(BluetoothLeAudio.ACTION_LE_AUDIO_CONNECTION_STATE_CHANGED);
        application.registerReceiver(leAudioIntentReceiver, intentFilter);
        application.registerReceiver(leAudioIntentReceiver, intentFilter,
                Context.RECEIVER_EXPORTED);
    }

    private void cleanupLeAudioProxy() {
@@ -760,7 +763,8 @@ public class BluetoothProxy {

        intentFilter = new IntentFilter();
        intentFilter.addAction(BluetoothVolumeControl.ACTION_CONNECTION_STATE_CHANGED);
        application.registerReceiver(volumeControlIntentReceiver, intentFilter);
        application.registerReceiver(volumeControlIntentReceiver, intentFilter,
                Context.RECEIVER_EXPORTED);
    }

    private void cleanupVolumeControlProxy() {
@@ -780,7 +784,8 @@ public class BluetoothProxy {
        intentFilter = new IntentFilter();
        intentFilter.addAction(BluetoothHapClient.ACTION_HAP_CONNECTION_STATE_CHANGED);
        intentFilter.addAction("android.bluetooth.action.HAP_DEVICE_AVAILABLE");
        application.registerReceiver(hapClientIntentReceiver, intentFilter);
        application.registerReceiver(hapClientIntentReceiver, intentFilter,
                Context.RECEIVER_EXPORTED);
    }

    private void cleanupHapProxy() {