Fix issue 2459650.
This change fixes a problem where an unwanted tone is generated by audio policy manager when a MT call is answered. This is because of a policy that replaces high visibility system sounds (ringtones, alarms...) by a beep when in call. There is a transitory phase while the call is being answered where the phone state is changed to IN_CALL but the ringtone is still playing. The audio policy manager then mutes the end of the ringtone and starts playing a beep in replacement because the ringtone is categorized as high visibility. The fix consists in changing the ringtone stream type from high visibility to low visibility. This is not a problem as the only actual use case where a ringtone would be generated while in call is if another call is received. But in this case, the phone system does not generate a ringtone but a call waiting tone instead. It is therefore not required to handle a ringtone as a high visibiltiy tone that must be somehow signaled to the user while in call.
This commit is contained in:
@@ -694,7 +694,9 @@ bool AudioSystem::isBluetoothScoDevice(audio_devices device)
|
|||||||
|
|
||||||
bool AudioSystem::isLowVisibility(stream_type stream)
|
bool AudioSystem::isLowVisibility(stream_type stream)
|
||||||
{
|
{
|
||||||
if (stream == AudioSystem::SYSTEM || stream == AudioSystem::NOTIFICATION) {
|
if (stream == AudioSystem::SYSTEM ||
|
||||||
|
stream == AudioSystem::NOTIFICATION ||
|
||||||
|
stream == AudioSystem::RING) {
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
Reference in New Issue
Block a user