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

Unified Diff: content/browser/bluetooth/web_bluetooth_service_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
« no previous file with comments | « no previous file | content/renderer/bluetooth/web_bluetooth_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/bluetooth/web_bluetooth_service_impl.cc
diff --git a/content/browser/bluetooth/web_bluetooth_service_impl.cc b/content/browser/bluetooth/web_bluetooth_service_impl.cc
index 5f99b71533b0c3e78ad77607c9db3ddcc7882d8d..66216c1119d13ffd40f32f1de175244bd583aa44 100644
--- a/content/browser/bluetooth/web_bluetooth_service_impl.cc
+++ b/content/browser/bluetooth/web_bluetooth_service_impl.cc
@@ -782,25 +782,12 @@ void WebBluetoothServiceImpl::OnGetDeviceSuccess(
allowed_devices_map_.AddDevice(GetOrigin(), device_address, options);
VLOG(1) << "Device: " << device->GetNameForDisplay();
- VLOG(1) << "UUIDs: ";
-
- mojo::Array<mojo::String> filtered_uuids;
- for (const BluetoothUUID& uuid : device->GetUUIDs()) {
- if (allowed_devices_map_.IsOriginAllowedToAccessService(
- GetOrigin(), device_id_for_origin, uuid)) {
- VLOG(1) << "\t Allowed: " << uuid.canonical_value();
- filtered_uuids.push_back(uuid.canonical_value());
- } else {
- VLOG(1) << "\t Not Allowed: " << uuid.canonical_value();
- }
- }
blink::mojom::WebBluetoothDevicePtr device_ptr =
blink::mojom::WebBluetoothDevice::New();
device_ptr->id = device_id_for_origin;
device_ptr->name = device->GetName() ? mojo::String(device->GetName().value())
: mojo::String(nullptr);
- device_ptr->uuids = std::move(filtered_uuids);
RecordRequestDeviceOutcome(UMARequestDeviceOutcome::SUCCESS);
callback.Run(blink::mojom::WebBluetoothResult::SUCCESS,
« no previous file with comments | « no previous file | content/renderer/bluetooth/web_bluetooth_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698