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

Unified Diff: content/renderer/bluetooth/web_bluetooth_impl.cc

Issue 2456613002: Remove BluetoothDevice.uuids attribute from WebBluetooth (Closed)
Patch Set: address more comments Created 4 years, 2 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: content/renderer/bluetooth/web_bluetooth_impl.cc
diff --git a/content/renderer/bluetooth/web_bluetooth_impl.cc b/content/renderer/bluetooth/web_bluetooth_impl.cc
index 5960a65f6487c2ffd68410a3df02043cf569157a..ebfcce61da8aec0458e0e6be632de281274c1177 100644
--- a/content/renderer/bluetooth/web_bluetooth_impl.cc
+++ b/content/renderer/bluetooth/web_bluetooth_impl.cc
@@ -186,15 +186,10 @@ void WebBluetoothImpl::OnRequestDeviceComplete(
const blink::mojom::WebBluetoothResult result,
blink::mojom::WebBluetoothDevicePtr device) {
if (result == blink::mojom::WebBluetoothResult::SUCCESS) {
- blink::WebVector<blink::WebString> uuids(device->uuids.size());
- for (size_t i = 0; i < device->uuids.size(); ++i)
- uuids[i] = blink::WebString::fromUTF8(device->uuids[i]);
-
callbacks->onSuccess(base::MakeUnique<blink::WebBluetoothDeviceInit>(
blink::WebString::fromUTF8(device->id.str()),
device->name.is_null() ? blink::WebString()
- : blink::WebString::fromUTF8(device->name),
- uuids));
+ : blink::WebString::fromUTF8(device->name)));
} else {
callbacks->onError(ToInt32(result));
}

Powered by Google App Engine
This is Rietveld 408576698