summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2012-06-07 09:12:34 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2012-06-07 09:12:34 -0700
commitfc6e3fe41473c76bcc1efc70bcc241b943988343 (patch)
tree8a8975a267dfc3b91f9c18765ae1668821a486f1
parent5d379e191e895a67e876cf2d2708c2b9d3f4c831 (diff)
parent5568b826b6b9b084f76b777db8b0411c7565e870 (diff)
downloadhardware_libhardware_legacy-fc6e3fe41473c76bcc1efc70bcc241b943988343.zip
hardware_libhardware_legacy-fc6e3fe41473c76bcc1efc70bcc241b943988343.tar.gz
hardware_libhardware_legacy-fc6e3fe41473c76bcc1efc70bcc241b943988343.tar.bz2
am 5568b826: Merge "audio policy: fix notification volume limitation" into jb-dev
* commit '5568b826b6b9b084f76b777db8b0411c7565e870': audio policy: fix notification volume limitation
-rw-r--r--audio/AudioPolicyManagerBase.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/audio/AudioPolicyManagerBase.cpp b/audio/AudioPolicyManagerBase.cpp
index fcee6ae..ee758b3 100644
--- a/audio/AudioPolicyManagerBase.cpp
+++ b/audio/AudioPolicyManagerBase.cpp
@@ -2642,7 +2642,8 @@ float AudioPolicyManagerBase::computeVolume(int stream,
// when the phone is ringing we must consider that music could have been paused just before
// by the music application and behave as if music was active if the last music track was
// just stopped
- if (outputDesc->mRefCount[AudioSystem::MUSIC] || mLimitRingtoneVolume) {
+ if (isStreamActive(AudioSystem::MUSIC, SONIFICATION_HEADSET_MUSIC_DELAY) ||
+ mLimitRingtoneVolume) {
float musicVol = computeVolume(AudioSystem::MUSIC,
mStreams[AudioSystem::MUSIC].getVolumeIndex(device),
output,