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

Commit 6561845b authored by Donghyun Cho's avatar Donghyun Cho
Browse files

CEC: Ignore audio status update when system audio mode is off

Bug: 32052505
Test: Simulate receiving <Report Audio Status> while SAM is off
Change-Id: I9121928fc5a588f412b392fcfe76608391d92ad4
(cherry picked from commit 46b86aada358947869365ba9b06adcecbbc83c0f)
parent 3680b73c
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -967,6 +967,9 @@ public final class HdmiControlService extends SystemService {
    }

    void setAudioStatus(boolean mute, int volume) {
        if (!isTvDeviceEnabled() || !tv().isSystemAudioActivated()) {
            return;
        }
        AudioManager audioManager = getAudioManager();
        boolean muted = audioManager.isStreamMute(AudioManager.STREAM_MUSIC);
        if (mute) {