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

Unified Diff: chromeos/dbus/fake_bluetooth_media_transport_client.h

Issue 939753004: device/bluetooth: Implement Unregister() of BlueotoothAudioSinkChromeOS and disconnection-related c… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Changed volume_ back to uint16_t with a defined range. Created 5 years, 10 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
Index: chromeos/dbus/fake_bluetooth_media_transport_client.h
diff --git a/chromeos/dbus/fake_bluetooth_media_transport_client.h b/chromeos/dbus/fake_bluetooth_media_transport_client.h
index f88908f6111db8919c39632a6bac9022d075118a..2540a86c7540e36373c3c4bd3b32966e445f6723 100644
--- a/chromeos/dbus/fake_bluetooth_media_transport_client.h
+++ b/chromeos/dbus/fake_bluetooth_media_transport_client.h
@@ -17,6 +17,8 @@
namespace chromeos {
+class FakeBluetoothMediaEndpointServiceProvider;
+
class CHROMEOS_EXPORT FakeBluetoothMediaTransportClient
: public BluetoothMediaTransportClient {
public:
@@ -62,21 +64,29 @@ class CHROMEOS_EXPORT FakeBluetoothMediaTransportClient
const base::Closure& callback,
const ErrorCallback& error_callback) override;
- // Makes the transport valid/invalid for a given media endpoint path. The
- // transport object is assigned to the given endpoint if valid is true, false
+ // Makes the transport valid/invalid for a given media endpoint. The transport
+ // object is assigned to the given endpoint if valid is true, false
// otherwise.
- void SetValid(const dbus::ObjectPath& endpoint_path, bool valid);
+ void SetValid(FakeBluetoothMediaEndpointServiceProvider* endpoint,
+ bool valid);
+
+ // Gets the transport path associated with the given endpoint path.
+ dbus::ObjectPath GetTransportPath(const dbus::ObjectPath& endpoint_path);
private:
// Property callback passed while a Properties structure is created.
void OnPropertyChanged(const std::string& property_name);
+ // Map of endpoints with valid transport. Each pair is composed of an endpoint
+ // path and a transport path bound to that endpoint path.
+ std::map<dbus::ObjectPath, dbus::ObjectPath> endpoints_;
+
+ // The endpoint path associated with the transport object.
+ dbus::ObjectPath endpoint_path_;
+
// The path of the media transport object.
dbus::ObjectPath object_path_;
- // Indicates whether endpoints are assigned with the transport object.
- std::map<dbus::ObjectPath, bool> endpoints_;
-
// The fake property set of the media transport object.
scoped_ptr<Properties> properties_;

Powered by Google App Engine
This is Rietveld 408576698