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

Commit d06462c5 authored by Łukasz Rymanowski's avatar Łukasz Rymanowski Committed by Android (Google) Code Review
Browse files

Merge "leaudio: Fix direction bits" into tm-qpr-dev

parents 1e40e3d8 616267bf
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -100,14 +100,14 @@ public class LeAudioService extends ProfileService {
    private static final int AUDIO_DIRECTION_NONE = 0x00;

    /**
     * Indicates group audio support for input direction
     * Indicates group audio support for output direction
     */
    private static final int AUDIO_DIRECTION_INPUT_BIT = 0x01;
    private static final int AUDIO_DIRECTION_OUTPUT_BIT = 0x01;

    /**
     * Indicates group audio support for output direction
     * Indicates group audio support for input direction
     */
    private static final int AUDIO_DIRECTION_OUTPUT_BIT = 0x02;
    private static final int AUDIO_DIRECTION_INPUT_BIT = 0x02;

    private AdapterService mAdapterService;
    private DatabaseManager mDatabaseManager;
+8 −4
Original line number Diff line number Diff line
@@ -1045,7 +1045,8 @@ public class LeAudioServiceTest {
    @Test
    public void testGetActiveDevices() {
        int groupId = 1;
        int direction = 2;
        /* AUDIO_DIRECTION_OUTPUT_BIT = 0x01 */
        int direction = 1;
        int snkAudioLocation = 3;
        int srcAudioLocation = 4;
        int availableContexts = 5;
@@ -1295,7 +1296,8 @@ public class LeAudioServiceTest {
    @Test
    public void testLeadGroupDeviceDisconnects() {
        int groupId = 1;
        int direction = 2;
        /* AUDIO_DIRECTION_OUTPUT_BIT = 0x01 */
        int direction = 1;
        int snkAudioLocation = 3;
        int srcAudioLocation = 4;
        int availableContexts = 5;
@@ -1359,7 +1361,8 @@ public class LeAudioServiceTest {
    @Test
    public void testLeadGroupDeviceReconnects() {
        int groupId = 1;
        int direction = 2;
        /* AUDIO_DIRECTION_OUTPUT_BIT = 0x01 */
        int direction = 1;
        int snkAudioLocation = 3;
        int srcAudioLocation = 4;
        int availableContexts = 5;
@@ -1426,7 +1429,8 @@ public class LeAudioServiceTest {
    public void testVolumeCache() {
        int groupId = 1;
        int volume = 100;
        int direction = 2;
        /* AUDIO_DIRECTION_OUTPUT_BIT = 0x01 */
        int direction = 1;
        int availableContexts = 4;

        doReturn(true).when(mNativeInterface).connectLeAudio(any(BluetoothDevice.class));