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

Unified Diff: chromeos/dbus/cras_audio_client.cc

Issue 14321002: Replace cras properties with the ones rolled down in service_constants.h. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/dbus/cras_audio_client.cc
diff --git a/chromeos/dbus/cras_audio_client.cc b/chromeos/dbus/cras_audio_client.cc
index bffa4d40cecf2b7ded287bc0d988201662de2f23..2ed9bdfb7a742a2d26b72eb59d042042dbfd24f8 100644
--- a/chromeos/dbus/cras_audio_client.cc
+++ b/chromeos/dbus/cras_audio_client.cc
@@ -11,20 +11,6 @@
#include "dbus/object_proxy.h"
#include "third_party/cros_system_api/dbus/service_constants.h"
-namespace {
-
-// TODO(jennyz): Remove this section and use the dbus properties constants
-// defined in service_constants.h, once the change is done in cros side for
-// service_constants.h and rolled down to chrome.
-const char kIsInputProperty[] = "IsInput";
-const char kIdProperty[] = "Id";
-const char kDeviceNameProperty[] = "DeviceName";
-const char kTypeProperty[] = "Type";
-const char kNameProperty[] = "Name";
-const char kActiveProperty[] = "Active";
-
-} // namespace
-
namespace chromeos {
// The CrasAudioClient implementation used in production.
@@ -348,22 +334,22 @@ class CrasAudioClientImpl : public CrasAudioClient {
return false;
}
- if (key == kIsInputProperty) {
+ if (key == cras::kIsInputProperty) {
if (!value_reader.PopBool(&node->is_input))
return false;
- } else if (key == kIdProperty) {
+ } else if (key == cras::kIdProperty) {
if (!value_reader.PopUint64(&node->id))
return false;
- } else if (key == kDeviceNameProperty) {
+ } else if (key == cras::kDeviceNameProperty) {
if (!value_reader.PopString(&node->device_name))
return false;
- } else if (key == kTypeProperty) {
+ } else if (key == cras::kTypeProperty) {
if (!value_reader.PopString(&node->type))
return false;
- } else if (key == kNameProperty) {
+ } else if (key == cras::kNameProperty) {
if (!value_reader.PopString(&node->name))
return false;
- } else if (key == kActiveProperty) {
+ } else if (key == cras::kActiveProperty) {
if (!value_reader.PopBool(&node->active))
return false;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698