summaryrefslogtreecommitdiffstats
path: root/libs/audioflinger
diff options
context:
space:
mode:
authorEric Laurent <>2009-03-26 01:57:59 -0700
committerThe Android Open Source Project <initial-contribution@android.com>2009-03-26 01:57:59 -0700
commiteeea9222132fe5979e40dcc85f5eba300157dfbc (patch)
tree222d6010f339edc928cfde08d716e21430197367 /libs/audioflinger
parentcc95667b9cb1c8e61b4addd6b1aff7f09902d5c8 (diff)
downloadframeworks_base-eeea9222132fe5979e40dcc85f5eba300157dfbc.zip
frameworks_base-eeea9222132fe5979e40dcc85f5eba300157dfbc.tar.gz
frameworks_base-eeea9222132fe5979e40dcc85f5eba300157dfbc.tar.bz2
Automated import from //branches/cupcake/...@142889,142889
Diffstat (limited to 'libs/audioflinger')
-rw-r--r--libs/audioflinger/AudioFlinger.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/libs/audioflinger/AudioFlinger.cpp b/libs/audioflinger/AudioFlinger.cpp
index 9ba7f90..b9ecdd8 100644
--- a/libs/audioflinger/AudioFlinger.cpp
+++ b/libs/audioflinger/AudioFlinger.cpp
@@ -243,7 +243,8 @@ bool AudioFlinger::streamForcedToSpeaker(int streamType)
// AudioSystem::routedToA2dpOutput(streamType) == false
return (streamType == AudioSystem::RING ||
streamType == AudioSystem::ALARM ||
- streamType == AudioSystem::NOTIFICATION);
+ streamType == AudioSystem::NOTIFICATION ||
+ streamType == AudioSystem::ENFORCED_AUDIBLE);
}
status_t AudioFlinger::dumpClients(int fd, const Vector<String16>& args)
@@ -645,7 +646,8 @@ status_t AudioFlinger::setStreamVolume(int stream, float value)
return PERMISSION_DENIED;
}
- if (uint32_t(stream) >= AudioSystem::NUM_STREAM_TYPES) {
+ if (uint32_t(stream) >= AudioSystem::NUM_STREAM_TYPES ||
+ uint32_t(stream) == AudioSystem::ENFORCED_AUDIBLE) {
return BAD_VALUE;
}
@@ -680,7 +682,8 @@ status_t AudioFlinger::setStreamMute(int stream, bool muted)
return PERMISSION_DENIED;
}
- if (uint32_t(stream) >= AudioSystem::NUM_STREAM_TYPES) {
+ if (uint32_t(stream) >= AudioSystem::NUM_STREAM_TYPES ||
+ uint32_t(stream) == AudioSystem::ENFORCED_AUDIBLE) {
return BAD_VALUE;
}