Chromium Code Reviews| Index: device/bluetooth/bluetooth_socket_chromeos.h |
| diff --git a/device/bluetooth/bluetooth_socket_chromeos.h b/device/bluetooth/bluetooth_socket_chromeos.h |
| index 6ea2c210a8bcd977d783ec0894fc951af109c76a..81f373266f048a7a37d5cdacb75f451db200d7bb 100644 |
| --- a/device/bluetooth/bluetooth_socket_chromeos.h |
| +++ b/device/bluetooth/bluetooth_socket_chromeos.h |
| @@ -26,6 +26,8 @@ class FileDescriptor; |
| namespace chromeos { |
| class BluetoothDeviceChromeOS; |
| +class BluetoothAdapterChromeOS; |
| +class BluetoothAdapterProfileChromeOS; |
| // The BluetoothSocketChromeOS class implements BluetoothSocket for the |
| // Chrome OS platform. |
| @@ -75,9 +77,6 @@ class CHROMEOS_EXPORT BluetoothSocketChromeOS |
| virtual void Accept(const AcceptCompletionCallback& success_callback, |
| const ErrorCompletionCallback& error_callback) override; |
| - // Returns the object path of the socket. |
| - const dbus::ObjectPath& object_path() const { return object_path_; } |
| - |
| protected: |
| virtual ~BluetoothSocketChromeOS(); |
| @@ -87,12 +86,12 @@ class CHROMEOS_EXPORT BluetoothSocketChromeOS |
| scoped_refptr<device::BluetoothSocketThread> socket_thread); |
| // Register the underlying profile client object with the Bluetooth Daemon. |
| - void RegisterProfile(const base::Closure& success_callback, |
| + void RegisterProfile(BluetoothAdapterChromeOS* adapter, |
| + const base::Closure& success_callback, |
| const ErrorCompletionCallback& error_callback); |
| void OnRegisterProfile(const base::Closure& success_callback, |
| const ErrorCompletionCallback& error_callback); |
| void OnRegisterProfileError(const ErrorCompletionCallback& error_callback, |
| - const std::string& error_name, |
| const std::string& error_message); |
| // Called by dbus:: on completion of the ConnectProfile() method. |
| @@ -108,8 +107,7 @@ class CHROMEOS_EXPORT BluetoothSocketChromeOS |
| // Called by dbus:: on completion of the RegisterProfile() method call |
| // triggered as a result of the adapter becoming present again. |
| void OnInternalRegisterProfile(); |
| - void OnInternalRegisterProfileError(const std::string& error_name, |
| - const std::string& error_message); |
| + void OnInternalRegisterProfileError(const std::string& error_message); |
| // BluetoothProfileServiceProvider::Delegate: |
| virtual void Released() override; |
| @@ -152,13 +150,8 @@ class CHROMEOS_EXPORT BluetoothSocketChromeOS |
| // Unregister the underlying profile client object from the Bluetooth Daemon. |
| void UnregisterProfile(); |
| - void OnUnregisterProfile(const dbus::ObjectPath& object_path); |
| - void OnUnregisterProfileError(const dbus::ObjectPath& object_path, |
| - const std::string& error_name, |
| - const std::string& error_message); |
| - // Adapter the profile is registered against; this is only present when the |
| - // socket is listening. |
| + // Adapter the profile is registered against |
| scoped_refptr<device::BluetoothAdapter> adapter_; |
| // Address and D-Bus object path of the device being connected to, empty and |
| @@ -172,12 +165,8 @@ class CHROMEOS_EXPORT BluetoothSocketChromeOS |
| // Copy of the profile options used for registering the profile. |
| scoped_ptr<BluetoothProfileManagerClient::Options> options_; |
| - // Object path of the local profile D-Bus object. |
| - dbus::ObjectPath object_path_; |
| - |
| - // Local profile D-Bus object used for receiving profile delegate methods |
| - // from BlueZ. |
| - scoped_ptr<BluetoothProfileServiceProvider> profile_; |
| + // The profile registered with the adatper for this socket. |
|
armansito
2015/01/21 01:44:48
nit: s/adatper/adapter/
Marie Janssen
2015/01/22 21:55:33
Done.
|
| + BluetoothAdapterProfileChromeOS* profile_; |
| // Pending request to an Accept() call. |
| struct AcceptRequest { |