Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(145)

Unified Diff: chromeos/audio/audio_device.cc

Issue 2222903002: audio_device: Add lineout node type (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chromeos/audio/audio_device.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/audio/audio_device.cc
diff --git a/chromeos/audio/audio_device.cc b/chromeos/audio/audio_device.cc
index 1d626b793846e30eceb17faf828bc8335b238838..df84314ceee267ec52d67689bd484fd28eadc5a6 100644
--- a/chromeos/audio/audio_device.cc
+++ b/chromeos/audio/audio_device.cc
@@ -25,6 +25,7 @@ uint8_t GetDevicePriority(AudioDeviceType type, bool is_input) {
return 0;
switch (type) {
case AUDIO_TYPE_HEADPHONE:
+ case AUDIO_TYPE_LINEOUT:
case AUDIO_TYPE_MIC:
case AUDIO_TYPE_USB:
case AUDIO_TYPE_BLUETOOTH:
@@ -67,6 +68,8 @@ std::string AudioDevice::GetTypeString(AudioDeviceType type) {
return "KEYBOARD_MIC";
case AUDIO_TYPE_HOTWORD:
return "HOTWORD";
+ case AUDIO_TYPE_LINEOUT:
+ return "LINEOUT";
case AUDIO_TYPE_POST_MIX_LOOPBACK:
return "POST_MIX_LOOPBACK";
case AUDIO_TYPE_POST_DSP_LOOPBACK:
@@ -102,6 +105,8 @@ AudioDeviceType AudioDevice::GetAudioType(
return AUDIO_TYPE_HOTWORD;
else if (node_type.find("HOTWORD") != std::string::npos)
return AUDIO_TYPE_HOTWORD;
+ else if (node_type.find("LINEOUT") != std::string::npos)
+ return AUDIO_TYPE_LINEOUT;
else if (node_type.find("POST_MIX_LOOPBACK") != std::string::npos)
return AUDIO_TYPE_POST_MIX_LOOPBACK;
else if (node_type.find("POST_DSP_LOOPBACK") != std::string::npos)
« no previous file with comments | « chromeos/audio/audio_device.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698