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

Commit 63888753 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "LeAudioService: Add logs around mExposedActiveDevice"

parents d2537ad0 869cae97
Loading
Loading
Loading
Loading
+10 −5
Original line number Diff line number Diff line
@@ -1201,17 +1201,21 @@ public class LeAudioService extends ProfileService {
                byte[] addressBytes = Utils.getBytesFromAddress(address);
                BluetoothDevice device = mAdapterService.getDeviceFromByte(addressBytes);

                /* Don't expose already exposed active device */
                if (device.equals(mExposedActiveDevice)) {
                    return;
                }

                if (DBG) {
                    Log.d(TAG, " onAudioDevicesAdded: " + device + ", device type: "
                            + deviceInfo.getType() + ", isSink: " + deviceInfo.isSink()
                            + " isSource: " + deviceInfo.isSource());
                }

                /* Don't expose already exposed active device */
                if (device.equals(mExposedActiveDevice)) {
                    if (DBG) {
                        Log.d(TAG, " onAudioDevicesAdded: " + device + " is already exposed");
                    }
                    return;
                }


                if ((deviceInfo.isSink() && !device.equals(mActiveAudioOutDevice))
                        || (deviceInfo.isSource() && !device.equals(mActiveAudioInDevice))) {
                    Log.e(TAG, "Added device does not match to the one activated here. ("
@@ -3653,6 +3657,7 @@ public class LeAudioService extends ProfileService {
        ProfileService.println(sb, "  currentlyActiveGroupId: " + getActiveGroupId());
        ProfileService.println(sb, "  mActiveAudioOutDevice: " + mActiveAudioOutDevice);
        ProfileService.println(sb, "  mActiveAudioInDevice: " + mActiveAudioInDevice);
        ProfileService.println(sb, "  mExposedActiveDevice: " + mExposedActiveDevice);
        ProfileService.println(sb, "  mHfpHandoverDevice:" + mHfpHandoverDevice);
        ProfileService.println(sb, "  mLeAudioIsInbandRingtoneSupported:"
                                + mLeAudioInbandRingtoneSupportedByPlatform);