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

Unified Diff: chromeos/audio/audio_device.cc

Issue 1380103003: Store audio device's active state in preference (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix string format Created 4 years, 11 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') | chromeos/audio/audio_devices_pref_handler.h » ('j') | 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 5374194edd0eb1d7f3d1f01cc792941167ded10a..df48db51ed0c95447007e5ec113dbea052590829 100644
--- a/chromeos/audio/audio_device.cc
+++ b/chromeos/audio/audio_device.cc
@@ -109,16 +109,17 @@ AudioDeviceType AudioDevice::GetAudioType(
AudioDevice::AudioDevice()
: is_input(false),
id(0),
+ stable_device_id(0),
display_name(""),
type(AUDIO_TYPE_OTHER),
priority(0),
active(false),
- plugged_time(0) {
-}
+ plugged_time(0) {}
AudioDevice::AudioDevice(const AudioNode& node) {
is_input = node.is_input;
id = node.id;
+ stable_device_id = node.stable_device_id;
type = GetAudioType(node.type);
if (!node.name.empty() && node.name != "(default)")
display_name = node.name;
@@ -140,6 +141,9 @@ std::string AudioDevice::ToString() const {
"id = 0x%" PRIx64 " ",
id);
base::StringAppendF(&result,
+ "stable_device_id = 0x%" PRIx64 " ",
+ stable_device_id);
+ base::StringAppendF(&result,
"display_name = %s ",
display_name.c_str());
base::StringAppendF(&result,
« no previous file with comments | « chromeos/audio/audio_device.h ('k') | chromeos/audio/audio_devices_pref_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698