summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkeybuk@chromium.org <keybuk@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-05 21:11:11 +0000
committerkeybuk@chromium.org <keybuk@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-05 21:11:11 +0000
commit39e446866d6c61ce0124870c7c68c198344b6da5 (patch)
treef286797a6a5d174596e508e3601e5ea119e2ccac
parent19c5072ca6d1776ae1d03caaed67dc6dccc0bfe5 (diff)
downloadchromium_src-39e446866d6c61ce0124870c7c68c198344b6da5.zip
chromium_src-39e446866d6c61ce0124870c7c68c198344b6da5.tar.gz
chromium_src-39e446866d6c61ce0124870c7c68c198344b6da5.tar.bz2
Bluetooth: use updated constants
BUG=221813 TEST=device_unittests Review URL: https://chromiumcodereview.appspot.com/14964007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@204339 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chromeos/dbus/experimental_bluetooth_adapter_client.cc19
-rw-r--r--chromeos/dbus/experimental_bluetooth_agent_manager_client.cc6
-rw-r--r--chromeos/dbus/experimental_bluetooth_agent_service_provider.cc18
-rw-r--r--chromeos/dbus/experimental_bluetooth_device_client.cc25
-rw-r--r--chromeos/dbus/experimental_bluetooth_input_client.cc11
-rw-r--r--chromeos/dbus/experimental_bluetooth_profile_manager_client.cc6
-rw-r--r--chromeos/dbus/experimental_bluetooth_profile_service_provider.cc8
-rw-r--r--chromeos/dbus/fake_bluetooth_adapter_client.cc2
-rw-r--r--chromeos/dbus/fake_bluetooth_agent_manager_client.cc6
-rw-r--r--chromeos/dbus/fake_bluetooth_device_client.cc24
-rw-r--r--chromeos/dbus/fake_bluetooth_input_client.cc2
-rw-r--r--chromeos/dbus/fake_bluetooth_profile_manager_client.cc6
-rw-r--r--device/bluetooth/bluetooth_device_experimental_chromeos.cc20
13 files changed, 78 insertions, 75 deletions
diff --git a/chromeos/dbus/experimental_bluetooth_adapter_client.cc b/chromeos/dbus/experimental_bluetooth_adapter_client.cc
index 53486d9..9c6ac50 100644
--- a/chromeos/dbus/experimental_bluetooth_adapter_client.cc
+++ b/chromeos/dbus/experimental_bluetooth_adapter_client.cc
@@ -55,15 +55,16 @@ class ExperimentalBluetoothAdapterClientImpl
: bus_(bus),
weak_ptr_factory_(this) {
object_manager_ = bus_->GetObjectManager(
- bluetooth_manager::kBluetoothManagerServiceName,
- dbus::ObjectPath(bluetooth_manager::kBluetoothManagerServicePath));
+ bluetooth_object_manager::kBluetoothObjectManagerServiceName,
+ dbus::ObjectPath(
+ bluetooth_object_manager::kBluetoothObjectManagerServicePath));
object_manager_->RegisterInterface(
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface, this);
+ bluetooth_adapter::kBluetoothAdapterInterface, this);
}
virtual ~ExperimentalBluetoothAdapterClientImpl() {
object_manager_->UnregisterInterface(
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface);
+ bluetooth_adapter::kBluetoothAdapterInterface);
}
// ExperimentalBluetoothAdapterClient override.
@@ -83,7 +84,7 @@ class ExperimentalBluetoothAdapterClientImpl
// Returns the list of adapter object paths known to the system.
virtual std::vector<dbus::ObjectPath> GetAdapters() OVERRIDE {
return object_manager_->GetObjectsWithInterface(
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface);
+ bluetooth_adapter::kBluetoothAdapterInterface);
}
// dbus::ObjectManager::Interface override.
@@ -106,7 +107,7 @@ class ExperimentalBluetoothAdapterClientImpl
return static_cast<Properties*>(
object_manager_->GetProperties(
object_path,
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface));
+ bluetooth_adapter::kBluetoothAdapterInterface));
}
// ExperimentalBluetoothAdapterClient override.
@@ -114,7 +115,7 @@ class ExperimentalBluetoothAdapterClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface,
+ bluetooth_adapter::kBluetoothAdapterInterface,
bluetooth_adapter::kStartDiscovery);
dbus::ObjectProxy* object_proxy =
@@ -138,7 +139,7 @@ class ExperimentalBluetoothAdapterClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface,
+ bluetooth_adapter::kBluetoothAdapterInterface,
bluetooth_adapter::kStopDiscovery);
dbus::ObjectProxy* object_proxy =
@@ -163,7 +164,7 @@ class ExperimentalBluetoothAdapterClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface,
+ bluetooth_adapter::kBluetoothAdapterInterface,
bluetooth_adapter::kRemoveDevice);
dbus::MessageWriter writer(&method_call);
diff --git a/chromeos/dbus/experimental_bluetooth_agent_manager_client.cc b/chromeos/dbus/experimental_bluetooth_agent_manager_client.cc
index 4495357..177bc31 100644
--- a/chromeos/dbus/experimental_bluetooth_agent_manager_client.cc
+++ b/chromeos/dbus/experimental_bluetooth_agent_manager_client.cc
@@ -42,7 +42,7 @@ class ExperimentalBluetoothAgentManagerClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_agent_manager::kExperimentalBluetoothAgentManagerInterface,
+ bluetooth_agent_manager::kBluetoothAgentManagerInterface,
bluetooth_agent_manager::kRegisterAgent);
dbus::MessageWriter writer(&method_call);
@@ -63,7 +63,7 @@ class ExperimentalBluetoothAgentManagerClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_agent_manager::kExperimentalBluetoothAgentManagerInterface,
+ bluetooth_agent_manager::kBluetoothAgentManagerInterface,
bluetooth_agent_manager::kUnregisterAgent);
dbus::MessageWriter writer(&method_call);
@@ -85,7 +85,7 @@ class ExperimentalBluetoothAgentManagerClientImpl
const ErrorCallback& error_callback)
OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_agent_manager::kExperimentalBluetoothAgentManagerInterface,
+ bluetooth_agent_manager::kBluetoothAgentManagerInterface,
bluetooth_agent_manager::kRequestDefaultAgent);
dbus::MessageWriter writer(&method_call);
diff --git a/chromeos/dbus/experimental_bluetooth_agent_service_provider.cc b/chromeos/dbus/experimental_bluetooth_agent_service_provider.cc
index 3878df6..7ee4580 100644
--- a/chromeos/dbus/experimental_bluetooth_agent_service_provider.cc
+++ b/chromeos/dbus/experimental_bluetooth_agent_service_provider.cc
@@ -39,7 +39,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
exported_object_ = bus_->GetExportedObject(object_path_);
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kRelease,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::Release,
@@ -49,7 +49,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kRequestPinCode,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::RequestPinCode,
@@ -59,7 +59,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kDisplayPinCode,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::DisplayPinCode,
@@ -69,7 +69,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kRequestPasskey,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::RequestPasskey,
@@ -79,7 +79,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kDisplayPasskey,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::DisplayPasskey,
@@ -89,7 +89,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kRequestConfirmation,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::RequestConfirmation,
@@ -99,7 +99,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kRequestAuthorization,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::RequestAuthorization,
@@ -109,7 +109,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kAuthorizeService,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::AuthorizeService,
@@ -119,7 +119,7 @@ class ExperimentalBluetoothAgentServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_agent::kExperimentalBluetoothAgentInterface,
+ bluetooth_agent::kBluetoothAgentInterface,
bluetooth_agent::kCancel,
base::Bind(
&ExperimentalBluetoothAgentServiceProviderImpl::Cancel,
diff --git a/chromeos/dbus/experimental_bluetooth_device_client.cc b/chromeos/dbus/experimental_bluetooth_device_client.cc
index 7cfc88f..bf50ab0 100644
--- a/chromeos/dbus/experimental_bluetooth_device_client.cc
+++ b/chromeos/dbus/experimental_bluetooth_device_client.cc
@@ -57,15 +57,16 @@ class ExperimentalBluetoothDeviceClientImpl
: bus_(bus),
weak_ptr_factory_(this) {
object_manager_ = bus_->GetObjectManager(
- bluetooth_manager::kBluetoothManagerServiceName,
- dbus::ObjectPath(bluetooth_manager::kBluetoothManagerServicePath));
+ bluetooth_object_manager::kBluetoothObjectManagerServiceName,
+ dbus::ObjectPath(
+ bluetooth_object_manager::kBluetoothObjectManagerServicePath));
object_manager_->RegisterInterface(
- bluetooth_device::kExperimentalBluetoothDeviceInterface, this);
+ bluetooth_device::kBluetoothDeviceInterface, this);
}
virtual ~ExperimentalBluetoothDeviceClientImpl() {
object_manager_->UnregisterInterface(
- bluetooth_device::kExperimentalBluetoothDeviceInterface);
+ bluetooth_device::kBluetoothDeviceInterface);
}
// ExperimentalBluetoothDeviceClient override.
@@ -101,7 +102,7 @@ class ExperimentalBluetoothDeviceClientImpl
const dbus::ObjectPath& adapter_path) OVERRIDE {
std::vector<dbus::ObjectPath> object_paths, device_paths;
device_paths = object_manager_->GetObjectsWithInterface(
- bluetooth_device::kExperimentalBluetoothDeviceInterface);
+ bluetooth_device::kBluetoothDeviceInterface);
for (std::vector<dbus::ObjectPath>::iterator iter = device_paths.begin();
iter != device_paths.end(); ++iter) {
Properties* properties = GetProperties(*iter);
@@ -117,7 +118,7 @@ class ExperimentalBluetoothDeviceClientImpl
return static_cast<Properties*>(
object_manager_->GetProperties(
object_path,
- bluetooth_device::kExperimentalBluetoothDeviceInterface));
+ bluetooth_device::kBluetoothDeviceInterface));
}
// ExperimentalBluetoothDeviceClient override.
@@ -125,7 +126,7 @@ class ExperimentalBluetoothDeviceClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_device::kExperimentalBluetoothDeviceInterface,
+ bluetooth_device::kBluetoothDeviceInterface,
bluetooth_device::kConnect);
dbus::ObjectProxy* object_proxy =
@@ -150,7 +151,7 @@ class ExperimentalBluetoothDeviceClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_device::kExperimentalBluetoothDeviceInterface,
+ bluetooth_device::kBluetoothDeviceInterface,
bluetooth_device::kDisconnect);
dbus::ObjectProxy* object_proxy =
@@ -175,7 +176,7 @@ class ExperimentalBluetoothDeviceClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_device::kExperimentalBluetoothDeviceInterface,
+ bluetooth_device::kBluetoothDeviceInterface,
bluetooth_device::kConnectProfile);
dbus::MessageWriter writer(&method_call);
@@ -205,7 +206,7 @@ class ExperimentalBluetoothDeviceClientImpl
const ErrorCallback& error_callback)
OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_device::kExperimentalBluetoothDeviceInterface,
+ bluetooth_device::kBluetoothDeviceInterface,
bluetooth_device::kDisconnectProfile);
dbus::MessageWriter writer(&method_call);
@@ -232,7 +233,7 @@ class ExperimentalBluetoothDeviceClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_device::kExperimentalBluetoothDeviceInterface,
+ bluetooth_device::kBluetoothDeviceInterface,
bluetooth_device::kPair);
dbus::ObjectProxy* object_proxy =
@@ -258,7 +259,7 @@ class ExperimentalBluetoothDeviceClientImpl
const ErrorCallback& error_callback)
OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_device::kExperimentalBluetoothDeviceInterface,
+ bluetooth_device::kBluetoothDeviceInterface,
bluetooth_device::kCancelPairing);
dbus::ObjectProxy* object_proxy =
diff --git a/chromeos/dbus/experimental_bluetooth_input_client.cc b/chromeos/dbus/experimental_bluetooth_input_client.cc
index aee73c3..ccbc896 100644
--- a/chromeos/dbus/experimental_bluetooth_input_client.cc
+++ b/chromeos/dbus/experimental_bluetooth_input_client.cc
@@ -39,15 +39,16 @@ class ExperimentalBluetoothInputClientImpl
: bus_(bus),
weak_ptr_factory_(this) {
object_manager_ = bus_->GetObjectManager(
- bluetooth_manager::kBluetoothManagerServiceName,
- dbus::ObjectPath(bluetooth_manager::kBluetoothManagerServicePath));
+ bluetooth_object_manager::kBluetoothObjectManagerServiceName,
+ dbus::ObjectPath(
+ bluetooth_object_manager::kBluetoothObjectManagerServicePath));
object_manager_->RegisterInterface(
- bluetooth_input::kExperimentalBluetoothInputInterface, this);
+ bluetooth_input::kBluetoothInputInterface, this);
}
virtual ~ExperimentalBluetoothInputClientImpl() {
object_manager_->UnregisterInterface(
- bluetooth_input::kExperimentalBluetoothInputInterface);
+ bluetooth_input::kBluetoothInputInterface);
}
// ExperimentalBluetoothInputClient override.
@@ -84,7 +85,7 @@ class ExperimentalBluetoothInputClientImpl
return static_cast<Properties*>(
object_manager_->GetProperties(
object_path,
- bluetooth_input::kExperimentalBluetoothInputInterface));
+ bluetooth_input::kBluetoothInputInterface));
}
private:
diff --git a/chromeos/dbus/experimental_bluetooth_profile_manager_client.cc b/chromeos/dbus/experimental_bluetooth_profile_manager_client.cc
index 4f5fc27..1d3562e 100644
--- a/chromeos/dbus/experimental_bluetooth_profile_manager_client.cc
+++ b/chromeos/dbus/experimental_bluetooth_profile_manager_client.cc
@@ -54,7 +54,7 @@ class ExperimentalBluetoothProfileManagerClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_profile_manager::kExperimentalBluetoothProfileManagerInterface,
+ bluetooth_profile_manager::kBluetoothProfileManagerInterface,
bluetooth_profile_manager::kRegisterProfile);
dbus::MessageWriter writer(&method_call);
@@ -177,8 +177,8 @@ class ExperimentalBluetoothProfileManagerClientImpl
const base::Closure& callback,
const ErrorCallback& error_callback) OVERRIDE {
dbus::MethodCall method_call(
- bluetooth_profile_manager::kExperimentalBluetoothProfileManagerInterface,
- bluetooth_profile_manager::kUnregisterProfile);
+ bluetooth_profile_manager::kBluetoothProfileManagerInterface,
+ bluetooth_profile_manager::kUnregisterProfile);
dbus::MessageWriter writer(&method_call);
writer.AppendObjectPath(profile_path);
diff --git a/chromeos/dbus/experimental_bluetooth_profile_service_provider.cc b/chromeos/dbus/experimental_bluetooth_profile_service_provider.cc
index 2b2384f..4d69e69 100644
--- a/chromeos/dbus/experimental_bluetooth_profile_service_provider.cc
+++ b/chromeos/dbus/experimental_bluetooth_profile_service_provider.cc
@@ -39,7 +39,7 @@ class ExperimentalBluetoothProfileServiceProviderImpl
exported_object_ = bus_->GetExportedObject(object_path_);
exported_object_->ExportMethod(
- bluetooth_profile::kExperimentalBluetoothProfileInterface,
+ bluetooth_profile::kBluetoothProfileInterface,
bluetooth_profile::kRelease,
base::Bind(
&ExperimentalBluetoothProfileServiceProviderImpl::Release,
@@ -49,7 +49,7 @@ class ExperimentalBluetoothProfileServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_profile::kExperimentalBluetoothProfileInterface,
+ bluetooth_profile::kBluetoothProfileInterface,
bluetooth_profile::kNewConnection,
base::Bind(
&ExperimentalBluetoothProfileServiceProviderImpl::NewConnection,
@@ -59,7 +59,7 @@ class ExperimentalBluetoothProfileServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_profile::kExperimentalBluetoothProfileInterface,
+ bluetooth_profile::kBluetoothProfileInterface,
bluetooth_profile::kRequestDisconnection,
base::Bind(
&ExperimentalBluetoothProfileServiceProviderImpl::RequestDisconnection,
@@ -69,7 +69,7 @@ class ExperimentalBluetoothProfileServiceProviderImpl
weak_ptr_factory_.GetWeakPtr()));
exported_object_->ExportMethod(
- bluetooth_profile::kExperimentalBluetoothProfileInterface,
+ bluetooth_profile::kBluetoothProfileInterface,
bluetooth_profile::kCancel,
base::Bind(
&ExperimentalBluetoothProfileServiceProviderImpl::Cancel,
diff --git a/chromeos/dbus/fake_bluetooth_adapter_client.cc b/chromeos/dbus/fake_bluetooth_adapter_client.cc
index 9209f9d..695579d 100644
--- a/chromeos/dbus/fake_bluetooth_adapter_client.cc
+++ b/chromeos/dbus/fake_bluetooth_adapter_client.cc
@@ -40,7 +40,7 @@ FakeBluetoothAdapterClient::Properties::Properties(
const PropertyChangedCallback& callback)
: ExperimentalBluetoothAdapterClient::Properties(
NULL,
- bluetooth_adapter::kExperimentalBluetoothAdapterInterface,
+ bluetooth_adapter::kBluetoothAdapterInterface,
callback) {
}
diff --git a/chromeos/dbus/fake_bluetooth_agent_manager_client.cc b/chromeos/dbus/fake_bluetooth_agent_manager_client.cc
index f7fc81e..57759ff 100644
--- a/chromeos/dbus/fake_bluetooth_agent_manager_client.cc
+++ b/chromeos/dbus/fake_bluetooth_agent_manager_client.cc
@@ -27,10 +27,10 @@ void FakeBluetoothAgentManagerClient::RegisterAgent(
VLOG(1) << "RegisterAgent: " << agent_path.value();
if (service_provider_ == NULL) {
- error_callback.Run(bluetooth_adapter::kErrorFailed,
+ error_callback.Run(bluetooth_agent_manager::kErrorInvalidArguments,
"No agent created");
} else if (service_provider_->object_path_ != agent_path) {
- error_callback.Run(bluetooth_adapter::kErrorAlreadyExists,
+ error_callback.Run(bluetooth_agent_manager::kErrorAlreadyExists,
"Agent already registered");
} else {
callback.Run();
@@ -43,7 +43,7 @@ void FakeBluetoothAgentManagerClient::UnregisterAgent(
const ErrorCallback& error_callback) {
VLOG(1) << "UnregisterAgent: " << agent_path.value();
if (service_provider_ != NULL) {
- error_callback.Run(bluetooth_adapter::kErrorFailed,
+ error_callback.Run(bluetooth_agent_manager::kErrorInvalidArguments,
"Agent still registered");
} else {
callback.Run();
diff --git a/chromeos/dbus/fake_bluetooth_device_client.cc b/chromeos/dbus/fake_bluetooth_device_client.cc
index 60fd5e4..124cd73 100644
--- a/chromeos/dbus/fake_bluetooth_device_client.cc
+++ b/chromeos/dbus/fake_bluetooth_device_client.cc
@@ -158,7 +158,7 @@ FakeBluetoothDeviceClient::Properties::Properties(
const PropertyChangedCallback& callback)
: ExperimentalBluetoothDeviceClient::Properties(
NULL,
- bluetooth_device::kExperimentalBluetoothDeviceInterface,
+ bluetooth_device::kBluetoothDeviceInterface,
callback) {
}
@@ -263,12 +263,12 @@ void FakeBluetoothDeviceClient::Connect(
if (properties->paired.value() != true &&
object_path != dbus::ObjectPath(kMicrosoftMousePath)) {
// Must be paired.
- error_callback.Run(bluetooth_adapter::kErrorFailed, "Not paired");
+ error_callback.Run(bluetooth_device::kErrorFailed, "Not paired");
return;
} else if (properties->paired.value() == true &&
object_path == dbus::ObjectPath(kUnconnectableDevicePath)) {
// Must not be paired
- error_callback.Run(bluetooth_adapter::kErrorFailed,
+ error_callback.Run(bluetooth_device::kErrorFailed,
"Connection fails while paired");
return;
}
@@ -824,7 +824,7 @@ void FakeBluetoothDeviceClient::CompleteSimulatedPairing(
if (pairing_cancelled_) {
pairing_cancelled_ = false;
- error_callback.Run(bluetooth_adapter::kErrorAuthenticationCanceled,
+ error_callback.Run(bluetooth_device::kErrorAuthenticationCanceled,
"Cancaled");
} else {
Properties* properties = GetProperties(object_path);
@@ -841,7 +841,7 @@ void FakeBluetoothDeviceClient::TimeoutSimulatedPairing(
const ErrorCallback& error_callback) {
VLOG(1) << "TimeoutSimulatedPairing: " << object_path.value();
- error_callback.Run(bluetooth_adapter::kErrorAuthenticationTimeout,
+ error_callback.Run(bluetooth_device::kErrorAuthenticationTimeout,
"Timed out");
}
@@ -850,7 +850,7 @@ void FakeBluetoothDeviceClient::CancelSimulatedPairing(
const ErrorCallback& error_callback) {
VLOG(1) << "CancelSimulatedPairing: " << object_path.value();
- error_callback.Run(bluetooth_adapter::kErrorAuthenticationCanceled,
+ error_callback.Run(bluetooth_device::kErrorAuthenticationCanceled,
"Canceled");
}
@@ -859,7 +859,7 @@ void FakeBluetoothDeviceClient::RejectSimulatedPairing(
const ErrorCallback& error_callback) {
VLOG(1) << "RejectSimulatedPairing: " << object_path.value();
- error_callback.Run(bluetooth_adapter::kErrorAuthenticationRejected,
+ error_callback.Run(bluetooth_device::kErrorAuthenticationRejected,
"Rejected");
}
@@ -868,7 +868,7 @@ void FakeBluetoothDeviceClient::FailSimulatedPairing(
const ErrorCallback& error_callback) {
VLOG(1) << "FailSimulatedPairing: " << object_path.value();
- error_callback.Run(bluetooth_adapter::kErrorFailed, "Failed");
+ error_callback.Run(bluetooth_device::kErrorFailed, "Failed");
}
void FakeBluetoothDeviceClient::AddInputDeviceIfNeeded(
@@ -1041,11 +1041,11 @@ void FakeBluetoothDeviceClient::ConnectionCallback(
} else if (status ==
ExperimentalBluetoothProfileServiceProvider::Delegate::CANCELLED) {
// TODO(keybuk): tear down this side of the connection
- error_callback.Run(bluetooth_adapter::kErrorFailed, "Canceled");
+ error_callback.Run(bluetooth_device::kErrorFailed, "Canceled");
} else if (status ==
ExperimentalBluetoothProfileServiceProvider::Delegate::REJECTED) {
// TODO(keybuk): tear down this side of the connection
- error_callback.Run(bluetooth_adapter::kErrorFailed, "Rejected");
+ error_callback.Run(bluetooth_device::kErrorFailed, "Rejected");
}
}
@@ -1062,10 +1062,10 @@ void FakeBluetoothDeviceClient::DisconnectionCallback(
callback.Run();
} else if (status ==
ExperimentalBluetoothProfileServiceProvider::Delegate::CANCELLED) {
- error_callback.Run(bluetooth_adapter::kErrorFailed, "Canceled");
+ error_callback.Run(bluetooth_device::kErrorFailed, "Canceled");
} else if (status ==
ExperimentalBluetoothProfileServiceProvider::Delegate::REJECTED) {
- error_callback.Run(bluetooth_adapter::kErrorFailed, "Rejected");
+ error_callback.Run(bluetooth_device::kErrorFailed, "Rejected");
}
}
diff --git a/chromeos/dbus/fake_bluetooth_input_client.cc b/chromeos/dbus/fake_bluetooth_input_client.cc
index 841eae3..bb3523e 100644
--- a/chromeos/dbus/fake_bluetooth_input_client.cc
+++ b/chromeos/dbus/fake_bluetooth_input_client.cc
@@ -22,7 +22,7 @@ FakeBluetoothInputClient::Properties::Properties(
const PropertyChangedCallback& callback)
: ExperimentalBluetoothInputClient::Properties(
NULL,
- bluetooth_input::kExperimentalBluetoothInputInterface,
+ bluetooth_input::kBluetoothInputInterface,
callback) {
}
diff --git a/chromeos/dbus/fake_bluetooth_profile_manager_client.cc b/chromeos/dbus/fake_bluetooth_profile_manager_client.cc
index 2f2fb8e..4c7e0a4 100644
--- a/chromeos/dbus/fake_bluetooth_profile_manager_client.cc
+++ b/chromeos/dbus/fake_bluetooth_profile_manager_client.cc
@@ -41,12 +41,12 @@ void FakeBluetoothProfileManagerClient::RegisterProfile(
ServiceProviderMap::iterator iter = service_provider_map_.find(profile_path);
if (iter == service_provider_map_.end()) {
- error_callback.Run(bluetooth_adapter::kErrorFailed,
+ error_callback.Run(bluetooth_profile_manager::kErrorInvalidArguments,
"No profile created");
} else {
ProfileMap::iterator piter = profile_map_.find(uuid);
if (piter != profile_map_.end()) {
- error_callback.Run(bluetooth_adapter::kErrorAlreadyExists,
+ error_callback.Run(bluetooth_profile_manager::kErrorAlreadyExists,
"Profile already registered");
} else {
profile_map_[uuid] = profile_path;
@@ -63,7 +63,7 @@ void FakeBluetoothProfileManagerClient::UnregisterProfile(
ServiceProviderMap::iterator iter = service_provider_map_.find(profile_path);
if (iter != service_provider_map_.end()) {
- error_callback.Run(bluetooth_adapter::kErrorFailed,
+ error_callback.Run(bluetooth_profile_manager::kErrorInvalidArguments,
"Profile still registered");
} else {
for (ProfileMap::iterator piter = profile_map_.begin();
diff --git a/device/bluetooth/bluetooth_device_experimental_chromeos.cc b/device/bluetooth/bluetooth_device_experimental_chromeos.cc
index c7296ba..595ff19 100644
--- a/device/bluetooth/bluetooth_device_experimental_chromeos.cc
+++ b/device/bluetooth/bluetooth_device_experimental_chromeos.cc
@@ -612,11 +612,11 @@ void BluetoothDeviceExperimentalChromeOS::OnConnectError(
// Determine the error code from error_name.
ConnectErrorCode error_code = ERROR_UNKNOWN;
- if (error_name == bluetooth_adapter::kErrorFailed) {
+ if (error_name == bluetooth_device::kErrorFailed) {
error_code = ERROR_FAILED;
- } else if (error_name == bluetooth_adapter::kErrorInProgress) {
+ } else if (error_name == bluetooth_device::kErrorInProgress) {
error_code = ERROR_INPROGRESS;
- } else if (error_name == bluetooth_adapter::kErrorNotSupported) {
+ } else if (error_name == bluetooth_device::kErrorNotSupported) {
error_code = ERROR_UNSUPPORTED_DEVICE;
}
@@ -659,7 +659,7 @@ void BluetoothDeviceExperimentalChromeOS::OnRegisterAgentError(
// Determine the error code from error_name.
ConnectErrorCode error_code = ERROR_UNKNOWN;
- if (error_name == bluetooth_adapter::kErrorAlreadyExists)
+ if (error_name == bluetooth_agent_manager::kErrorAlreadyExists)
error_code = ERROR_INPROGRESS;
RecordPairingResult(error_code);
@@ -697,17 +697,17 @@ void BluetoothDeviceExperimentalChromeOS::OnPairError(
// Determine the error code from error_name.
ConnectErrorCode error_code = ERROR_UNKNOWN;
- if (error_name == bluetooth_adapter::kErrorConnectionAttemptFailed) {
+ if (error_name == bluetooth_device::kErrorConnectionAttemptFailed) {
error_code = ERROR_FAILED;
- } else if (error_name == bluetooth_adapter::kErrorFailed) {
+ } else if (error_name == bluetooth_device::kErrorFailed) {
error_code = ERROR_FAILED;
- } else if (error_name == bluetooth_adapter::kErrorAuthenticationFailed) {
+ } else if (error_name == bluetooth_device::kErrorAuthenticationFailed) {
error_code = ERROR_AUTH_FAILED;
- } else if (error_name == bluetooth_adapter::kErrorAuthenticationCanceled) {
+ } else if (error_name == bluetooth_device::kErrorAuthenticationCanceled) {
error_code = ERROR_AUTH_CANCELED;
- } else if (error_name == bluetooth_adapter::kErrorAuthenticationRejected) {
+ } else if (error_name == bluetooth_device::kErrorAuthenticationRejected) {
error_code = ERROR_AUTH_REJECTED;
- } else if (error_name == bluetooth_adapter::kErrorAuthenticationTimeout) {
+ } else if (error_name == bluetooth_device::kErrorAuthenticationTimeout) {
error_code = ERROR_AUTH_TIMEOUT;
}