OSDN Git Service

audio policy: fix mute delay when setting output device
authorEric Laurent <elaurent@google.com>
Thu, 8 May 2014 02:48:15 +0000 (19:48 -0700)
committerEric Laurent <elaurent@google.com>
Thu, 8 May 2014 21:10:17 +0000 (14:10 -0700)
commit99401131e58f2ff7f5571037d0d53b6f684e5543
tree0a94d258392b447c8a8c457f6f085f7118ced3ce
parenteee8fc78703dd77244407250402fe7464fe50fd3
audio policy: fix mute delay when setting output device

The duration of the temporary mute applied on each output
when switching device must be more than twice the actual delay
we wait for the mute to be effective at the output.
Otherwise some outputs with short latencies will be unmuted before the
device switch is actually executed.

This change makes sure that we take the maximum wait time into account
when requesting the delayed unmuting of each output.

Change-Id: Id92c201b47786082a44b6a5c1c8015273835a42e
services/audiopolicy/AudioPolicyManager.cpp