summaryrefslogtreecommitdiffstats
path: root/services/audiopolicy
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2014-12-16 21:36:33 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-12-16 21:36:33 +0000
commit679a14393639c70a653fe2a07f8de582d3a5de14 (patch)
tree50416eb5c99ea123f82235f443d57464356e41ba /services/audiopolicy
parent9632d33e21ec2631c75cc949e0c92c351fd6a447 (diff)
parentbe845fce36a65139eb353ba7442eba951b1ebee3 (diff)
downloadframeworks_av-679a14393639c70a653fe2a07f8de582d3a5de14.zip
frameworks_av-679a14393639c70a653fe2a07f8de582d3a5de14.tar.gz
frameworks_av-679a14393639c70a653fe2a07f8de582d3a5de14.tar.bz2
am be845fce: Merge "audiopolicy : Fix for incorrect input device selection" into lmp-mr1-dev
* commit 'be845fce36a65139eb353ba7442eba951b1ebee3': audiopolicy : Fix for incorrect input device selection
Diffstat (limited to 'services/audiopolicy')
-rw-r--r--services/audiopolicy/AudioPolicyManager.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/services/audiopolicy/AudioPolicyManager.cpp b/services/audiopolicy/AudioPolicyManager.cpp
index d2b0bcb..488d1f3 100644
--- a/services/audiopolicy/AudioPolicyManager.cpp
+++ b/services/audiopolicy/AudioPolicyManager.cpp
@@ -5127,6 +5127,9 @@ audio_devices_t AudioPolicyManager::getDeviceForInputSource(audio_source_t input
case AUDIO_SOURCE_MIC:
if (availableDeviceTypes & AUDIO_DEVICE_IN_BLUETOOTH_A2DP) {
device = AUDIO_DEVICE_IN_BLUETOOTH_A2DP;
+ } else if ((mForceUse[AUDIO_POLICY_FORCE_FOR_RECORD] == AUDIO_POLICY_FORCE_BT_SCO) &&
+ (availableDeviceTypes & AUDIO_DEVICE_IN_BLUETOOTH_SCO_HEADSET)) {
+ device = AUDIO_DEVICE_IN_BLUETOOTH_SCO_HEADSET;
} else if (availableDeviceTypes & AUDIO_DEVICE_IN_WIRED_HEADSET) {
device = AUDIO_DEVICE_IN_WIRED_HEADSET;
} else if (availableDeviceTypes & AUDIO_DEVICE_IN_USB_DEVICE) {