summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2010-08-13 17:23:53 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2010-08-13 17:23:53 -0700
commit029a74a38b56b97cbfe02b3d8e23536cea71609d (patch)
treebf057e15ee556a8a545662ab5da015e0a80b2278 /services
parent1b810073d8c627444294aee42a823e98796a328f (diff)
parentf28608cdf4f6a0075d0811ccd32123baf4daec31 (diff)
downloadframeworks_base-029a74a38b56b97cbfe02b3d8e23536cea71609d.zip
frameworks_base-029a74a38b56b97cbfe02b3d8e23536cea71609d.tar.gz
frameworks_base-029a74a38b56b97cbfe02b3d8e23536cea71609d.tar.bz2
am f28608cd: am c8d0d630: Merge "Fix issue 2909189: System property ro.audio.silent no longer mutes system." into gingerbread
Merge commit 'f28608cdf4f6a0075d0811ccd32123baf4daec31' * commit 'f28608cdf4f6a0075d0811ccd32123baf4daec31': Fix issue 2909189: System property ro.audio.silent no longer mutes system.
Diffstat (limited to 'services')
-rw-r--r--services/audioflinger/AudioFlinger.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/services/audioflinger/AudioFlinger.cpp b/services/audioflinger/AudioFlinger.cpp
index 1c7faa4..6e7633e 100644
--- a/services/audioflinger/AudioFlinger.cpp
+++ b/services/audioflinger/AudioFlinger.cpp
@@ -1675,6 +1675,9 @@ uint32_t AudioFlinger::MixerThread::prepareTracks_l(const SortedVector< wp<Track
float masterVolume = mMasterVolume;
bool masterMute = mMasterMute;
+ if (masterMute) {
+ masterVolume = 0;
+ }
#ifdef LVMX
bool tracksConnectedChanged = false;
bool stateChanged = false;
@@ -1696,10 +1699,7 @@ uint32_t AudioFlinger::MixerThread::prepareTracks_l(const SortedVector< wp<Track
// Delegate master volume control to effect in output mix effect chain if needed
sp<EffectChain> chain = getEffectChain_l(AudioSystem::SESSION_OUTPUT_MIX);
if (chain != 0) {
- uint32_t v = 0;
- if (!masterMute) {
- v = (uint32_t)(masterVolume * (1 << 24));
- }
+ uint32_t v = (uint32_t)(masterVolume * (1 << 24));
chain->setVolume_l(&v, &v);
masterVolume = (float)((v + (1 << 23)) >> 24);
chain.clear();