diff options
author | John Spurlock <jspurlock@google.com> | 2015-02-17 11:01:51 -0500 |
---|---|---|
committer | John Spurlock <jspurlock@google.com> | 2015-02-17 11:01:51 -0500 |
commit | a9dfbe8b122d746cf8841fe1b13d31e7e0fc9c52 (patch) | |
tree | 02a0041ca2847398ba0c7d6c940b3ad182814834 /media | |
parent | b25334ca3c2c4f792254bf8e628788d0b7c4775a (diff) | |
download | frameworks_base-a9dfbe8b122d746cf8841fe1b13d31e7e0fc9c52.zip frameworks_base-a9dfbe8b122d746cf8841fe1b13d31e7e0fc9c52.tar.gz frameworks_base-a9dfbe8b122d746cf8841fe1b13d31e7e0fc9c52.tar.bz2 |
Volume: Allow dialog to query "muteable" streams.
Similar to the existing ability to query streams affected
by ringer mode.
Bug:19260237
Change-Id: I76eb5ab6b7c7e3a4d73ac1909289c560194d4fe8
Diffstat (limited to 'media')
-rw-r--r-- | media/java/android/media/AudioManager.java | 13 | ||||
-rw-r--r-- | media/java/android/media/IAudioService.aidl | 2 |
2 files changed, 15 insertions, 0 deletions
diff --git a/media/java/android/media/AudioManager.java b/media/java/android/media/AudioManager.java index 7084eba..da89cf4 100644 --- a/media/java/android/media/AudioManager.java +++ b/media/java/android/media/AudioManager.java @@ -3334,6 +3334,19 @@ public class AudioManager { * Only useful for volume controllers. * @hide */ + public boolean isStreamAffectedByMute(int streamType) { + try { + return getService().isStreamAffectedByMute(streamType); + } catch (RemoteException e) { + Log.w(TAG, "Error calling isStreamAffectedByMute", e); + return false; + } + } + + /** + * Only useful for volume controllers. + * @hide + */ public void disableSafeMediaVolume() { try { getService().disableSafeMediaVolume(); diff --git a/media/java/android/media/IAudioService.aidl b/media/java/android/media/IAudioService.aidl index dabd9c2..17f5b59 100644 --- a/media/java/android/media/IAudioService.aidl +++ b/media/java/android/media/IAudioService.aidl @@ -202,6 +202,8 @@ interface IAudioService { boolean isStreamAffectedByRingerMode(int streamType); + boolean isStreamAffectedByMute(int streamType); + void disableSafeMediaVolume(); int setHdmiSystemAudioSupported(boolean on); |