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

Commit 542af895 authored by SongFerng Wang's avatar SongFerng Wang Committed by Automerger Merge Worker
Browse files

Merge "[LeAudioBroadcast] avoid the system register mBroadcastCallback again"...

Merge "[LeAudioBroadcast] avoid the system register mBroadcastCallback again" into tm-qpr-dev am: e2137ed5 am: d45c98a4

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/19259768



Change-Id: I760dd73d4e53a52bddeefb8cff6dcaf2fc15a59b
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 71311ac6 d45c98a4
Loading
Loading
Loading
Loading
+9 −5
Original line number Diff line number Diff line
@@ -87,19 +87,23 @@ public class LocalBluetoothLeBroadcast implements LocalBluetoothProfile {
            if (DEBUG) {
                Log.d(TAG, "Bluetooth service connected");
            }
            if(!mIsProfileReady) {
                mService = (BluetoothLeBroadcast) proxy;
                mIsProfileReady = true;
                registerServiceCallBack(mExecutor, mBroadcastCallback);
            }
        }

        @Override
        public void onServiceDisconnected(int profile) {
            if (DEBUG) {
                Log.d(TAG, "Bluetooth service disconnected");
            }
            if(mIsProfileReady) {
                mIsProfileReady = false;
                unregisterServiceCallBack(mBroadcastCallback);
            }
        }
    };

    private final BluetoothLeBroadcast.Callback mBroadcastCallback =