summaryrefslogtreecommitdiffstats
path: root/media/libmedia/AudioSystem.cpp
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2009-08-27 00:48:47 -0700
committerEric Laurent <elaurent@google.com>2009-08-27 05:58:10 -0700
commit327c27be19ad333c4835c84397152a0b2cb33081 (patch)
tree829f4323a59b922a47f6e7a60750be8e2c64a089 /media/libmedia/AudioSystem.cpp
parent42b1648212d31dbc63518ca8379f145fef1efcb8 (diff)
downloadframeworks_base-327c27be19ad333c4835c84397152a0b2cb33081.zip
frameworks_base-327c27be19ad333c4835c84397152a0b2cb33081.tar.gz
frameworks_base-327c27be19ad333c4835c84397152a0b2cb33081.tar.bz2
Fix issue 2045911: Camera Shutter tone does not play correctly while listening to music.
Add the possibility to delay routing and volume commands in AudioPolicyClientInterface. The delay is not blocking for the caller.
Diffstat (limited to 'media/libmedia/AudioSystem.cpp')
-rw-r--r--media/libmedia/AudioSystem.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/media/libmedia/AudioSystem.cpp b/media/libmedia/AudioSystem.cpp
index 98b55e9..bd1b2d7 100644
--- a/media/libmedia/AudioSystem.cpp
+++ b/media/libmedia/AudioSystem.cpp
@@ -883,5 +883,15 @@ status_t AudioParameter::getFloat(const String8& key, float& value)
return result;
}
+status_t AudioParameter::getAt(size_t index, String8& key, String8& value)
+{
+ if (mParameters.size() > index) {
+ key = mParameters.keyAt(index);
+ value = mParameters.valueAt(index);
+ return NO_ERROR;
+ } else {
+ return BAD_VALUE;
+ }
+}
}; // namespace android