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

Commit 182a6b1a authored by Ugo Yu's avatar Ugo Yu Committed by android-build-merger
Browse files

Merge "Update a2dp state to not playing while quitting the state machine" am:...

Merge "Update a2dp state to not playing while quitting the state machine" am: ca78a3b8 am: 6f55eb25
am: a1e3147b

Change-Id: I44f042e1bf7f4dd07ff6d58f699875133b1e10e7
parents a2200020 a1e3147b
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -127,6 +127,14 @@ final class A2dpStateMachine extends StateMachine {

    public void doQuit() {
        log("doQuit for device " + mDevice);
        if (mIsPlaying) {
            // Stop if auido is still playing
            log("doQuit: stopped playing " + mDevice);
            mIsPlaying = false;
            mA2dpService.setAvrcpAudioState(BluetoothA2dp.STATE_NOT_PLAYING);
            broadcastAudioState(BluetoothA2dp.STATE_NOT_PLAYING,
                                BluetoothA2dp.STATE_PLAYING);
        }
        quitNow();
    }