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

Unified Diff: third_party/WebKit/public/platform/modules/bluetooth/WebBluetooth.h

Issue 1861013005: bluetooth: Move GetCharacteristic(s) over to Mojo (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bluetooth-separate-tests-read-value
Patch Set: Address palmer's comments Created 4 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
Index: third_party/WebKit/public/platform/modules/bluetooth/WebBluetooth.h
diff --git a/third_party/WebKit/public/platform/modules/bluetooth/WebBluetooth.h b/third_party/WebKit/public/platform/modules/bluetooth/WebBluetooth.h
index 38f0f9d6059f16d653b1a0336a54efade880f960..96c108544ab26a78f1fd703f53c074986a5018d4 100644
--- a/third_party/WebKit/public/platform/modules/bluetooth/WebBluetooth.h
+++ b/third_party/WebKit/public/platform/modules/bluetooth/WebBluetooth.h
@@ -9,6 +9,7 @@
#include "public/platform/WebString.h"
#include "public/platform/WebVector.h"
#include "public/platform/modules/bluetooth/WebBluetoothError.h"
+#include "public/platform/modules/bluetooth/web_bluetooth.mojom.h"
#include <memory>
@@ -30,11 +31,8 @@ using WebBluetoothRemoteGATTServerConnectCallbacks = WebCallbacks<void, const We
// Success and failure callbacks for getPrimaryService.
using WebBluetoothGetPrimaryServiceCallbacks = WebCallbacks<std::unique_ptr<WebBluetoothRemoteGATTService>, const WebBluetoothError&>;
-// Success and failure callbacks for getCharacteristic.
-using WebBluetoothGetCharacteristicCallbacks = WebCallbacks<std::unique_ptr<WebBluetoothRemoteGATTCharacteristicInit>, const WebBluetoothError&>;
-
-// Success and failure callbacks for getCharacteristics.
-using WebBluetoothGetCharacteristicsCallbacks = WebCallbacks<std::unique_ptr<WebVector<WebBluetoothRemoteGATTCharacteristicInit*>>, const WebBluetoothError&>;
+// Success and failure callbacks for getCharacteristic(s).
+using WebBluetoothGetCharacteristicsCallbacks = WebCallbacks<const WebVector<WebBluetoothRemoteGATTCharacteristicInit*>&, const WebBluetoothError&>;
// Success and failure callbacks for readValue.
using WebBluetoothReadValueCallbacks = WebCallbacks<const WebVector<uint8_t>&, const WebBluetoothError&>;
@@ -69,10 +67,8 @@ public:
// BluetoothRemoteGATTService methods:
// See https://webbluetoothchrome.github.io/web-bluetooth/#idl-def-bluetoothgattservice
- virtual void getCharacteristic(const WebString& serviceInstanceID,
- const WebString& characteristicUUID,
- WebBluetoothGetCharacteristicCallbacks*) { }
virtual void getCharacteristics(const WebString& serviceInstanceID,
+ mojom::WebBluetoothGATTQueryQuantity,
const WebString& characteristicsUUID,
WebBluetoothGetCharacteristicsCallbacks*) = 0;

Powered by Google App Engine
This is Rietveld 408576698