Loading services/core/java/com/android/server/audio/AudioService.java +4 −2 Original line number Diff line number Diff line Loading @@ -3277,6 +3277,7 @@ public class AudioService extends IAudioService.Stub if (mUserSelectedVolumeControlStream) { // implies mVolumeControlStream != -1 streamType = mVolumeControlStream; } else { // TODO discard activity on a muted stream? final int maybeActiveStreamType = getActiveStreamType(suggestedStreamType); final boolean activeForReal; if (maybeActiveStreamType == AudioSystem.STREAM_RING Loading Loading @@ -3480,9 +3481,10 @@ public class AudioService extends IAudioService.Stub } } else if (isStreamMutedByRingerOrZenMode(streamTypeAlias) && streamState.mIsMuted) { // if the stream is currently muted streams by ringer/zen mode // then it cannot be unmuted (without FLAG_ALLOW_RINGER_MODES) // then it cannot be unmuted (without FLAG_ALLOW_RINGER_MODES) with an unmute or raise if (direction == AudioManager.ADJUST_TOGGLE_MUTE || direction == AudioManager.ADJUST_UNMUTE) { || direction == AudioManager.ADJUST_UNMUTE || direction == AudioManager.ADJUST_RAISE) { adjustVolume = false; } } Loading Loading
services/core/java/com/android/server/audio/AudioService.java +4 −2 Original line number Diff line number Diff line Loading @@ -3277,6 +3277,7 @@ public class AudioService extends IAudioService.Stub if (mUserSelectedVolumeControlStream) { // implies mVolumeControlStream != -1 streamType = mVolumeControlStream; } else { // TODO discard activity on a muted stream? final int maybeActiveStreamType = getActiveStreamType(suggestedStreamType); final boolean activeForReal; if (maybeActiveStreamType == AudioSystem.STREAM_RING Loading Loading @@ -3480,9 +3481,10 @@ public class AudioService extends IAudioService.Stub } } else if (isStreamMutedByRingerOrZenMode(streamTypeAlias) && streamState.mIsMuted) { // if the stream is currently muted streams by ringer/zen mode // then it cannot be unmuted (without FLAG_ALLOW_RINGER_MODES) // then it cannot be unmuted (without FLAG_ALLOW_RINGER_MODES) with an unmute or raise if (direction == AudioManager.ADJUST_TOGGLE_MUTE || direction == AudioManager.ADJUST_UNMUTE) { || direction == AudioManager.ADJUST_UNMUTE || direction == AudioManager.ADJUST_RAISE) { adjustVolume = false; } } Loading