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

Commit f740664c authored by Eric Laurent's avatar Eric Laurent
Browse files

fix unmute from volume panel on tablets

Changing STREAM_MUSIC from volume panel on tablets should exit silent
mode as does changing STREAM_RING on phones.

Issue 5970208.

Change-Id: Ia8ed62033da07a5d4dfcfa84b0b47b27414bdd9a
parent faac9294
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -711,9 +711,9 @@ public class AudioService extends IAudioService.Stub {
        final int oldIndex = streamState.getIndex(device,
                                                  (streamState.muteCount() != 0) /* lastAudible */);

        // setting ring or notifications volume to 0 on voice capable devices enters silent mode
        if (mVoiceCapable && (((flags & AudioManager.FLAG_ALLOW_RINGER_MODES) != 0) ||
                (mStreamVolumeAlias[streamType] == AudioSystem.STREAM_RING))) {
        // setting volume on master stream type also controls silent mode
        if (((flags & AudioManager.FLAG_ALLOW_RINGER_MODES) != 0) ||
                (mStreamVolumeAlias[streamType] == getMasterStreamType())) {
            int newRingerMode;
            if (index == 0) {
                newRingerMode = System.getInt(mContentResolver, System.VIBRATE_IN_SILENT, 1) == 1