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

Unified Diff: content/browser/bluetooth/frame_connected_bluetooth_devices.h

Issue 2718583002: Refactor WebBluetoothServiceClient in the web_bluetooth.mojom (Closed)
Patch Set: rebase Created 3 years, 9 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 | content/browser/bluetooth/frame_connected_bluetooth_devices.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/bluetooth/frame_connected_bluetooth_devices.h
diff --git a/content/browser/bluetooth/frame_connected_bluetooth_devices.h b/content/browser/bluetooth/frame_connected_bluetooth_devices.h
index 4168059d2f92b9a008f3fc0877e815d20a3b9c72..3c4dcf0ce30816d8a2a76757d0a5663b18a11549 100644
--- a/content/browser/bluetooth/frame_connected_bluetooth_devices.h
+++ b/content/browser/bluetooth/frame_connected_bluetooth_devices.h
@@ -12,6 +12,7 @@
#include "base/optional.h"
#include "content/common/bluetooth/web_bluetooth_device_id.h"
#include "content/common/content_export.h"
+#include "third_party/WebKit/public/platform/modules/bluetooth/web_bluetooth.mojom.h"
#include "url/origin.h"
namespace device {
@@ -20,6 +21,7 @@ class BluetoothGattConnection;
namespace content {
+struct GATTConnectionAndServerClient;
class RenderFrameHost;
class WebContentsImpl;
@@ -42,7 +44,8 @@ class CONTENT_EXPORT FrameConnectedBluetoothDevices final {
// If a connection doesn't exist already for |device_id|, adds a connection to
// the map and increases the WebContents count of connected devices.
void Insert(const WebBluetoothDeviceId& device_id,
- std::unique_ptr<device::BluetoothGattConnection> connection);
+ std::unique_ptr<device::BluetoothGattConnection> connection,
+ blink::mojom::WebBluetoothServerClientAssociatedPtr client);
// Deletes the BluetoothGattConnection for |device_id| and decrements the
// WebContents count of connected devices if |device_id| had a connection.
@@ -67,7 +70,7 @@ class CONTENT_EXPORT FrameConnectedBluetoothDevices final {
// Keeps the BluetoothGattConnection objects alive so that connections don't
// get closed.
std::unordered_map<WebBluetoothDeviceId,
- std::unique_ptr<device::BluetoothGattConnection>,
+ std::unique_ptr<GATTConnectionAndServerClient>,
WebBluetoothDeviceIdHash>
device_id_to_connection_map_;
« no previous file with comments | « no previous file | content/browser/bluetooth/frame_connected_bluetooth_devices.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698