| Index: third_party/WebKit/Source/modules/bluetooth/BluetoothRemoteGATTService.cpp
|
| diff --git a/third_party/WebKit/Source/modules/bluetooth/BluetoothRemoteGATTService.cpp b/third_party/WebKit/Source/modules/bluetooth/BluetoothRemoteGATTService.cpp
|
| index 0975449e8436330c06d1d2b7b34b329fafa4afd5..7787c93088c881b31f62daf48b9c0640b39e5a66 100644
|
| --- a/third_party/WebKit/Source/modules/bluetooth/BluetoothRemoteGATTService.cpp
|
| +++ b/third_party/WebKit/Source/modules/bluetooth/BluetoothRemoteGATTService.cpp
|
| @@ -4,6 +4,7 @@
|
|
|
| #include "modules/bluetooth/BluetoothRemoteGATTService.h"
|
|
|
| +#include <utility>
|
| #include "bindings/core/v8/ScriptPromise.h"
|
| #include "bindings/core/v8/ScriptPromiseResolver.h"
|
| #include "core/dom/DOMException.h"
|
| @@ -11,10 +12,10 @@
|
| #include "core/inspector/ConsoleMessage.h"
|
| #include "modules/bluetooth/Bluetooth.h"
|
| #include "modules/bluetooth/BluetoothError.h"
|
| +#include "modules/bluetooth/BluetoothMetrics.h"
|
| #include "modules/bluetooth/BluetoothRemoteGATTCharacteristic.h"
|
| #include "modules/bluetooth/BluetoothUUID.h"
|
| #include "wtf/PtrUtil.h"
|
| -#include <utility>
|
|
|
| namespace blink {
|
|
|
| @@ -89,6 +90,9 @@ ScriptPromise BluetoothRemoteGATTService::getCharacteristic(
|
| ScriptState* scriptState,
|
| const StringOrUnsignedLong& characteristic,
|
| ExceptionState& exceptionState) {
|
| + RecordWebBluetoothFunctionCall(
|
| + UMAWebBluetoothFunction::SERVICE_GET_CHARACTERISTIC);
|
| +
|
| String characteristicUUID =
|
| BluetoothUUID::getCharacteristic(characteristic, exceptionState);
|
| if (exceptionState.hadException())
|
| @@ -103,6 +107,9 @@ ScriptPromise BluetoothRemoteGATTService::getCharacteristics(
|
| ScriptState* scriptState,
|
| const StringOrUnsignedLong& characteristic,
|
| ExceptionState& exceptionState) {
|
| + RecordWebBluetoothFunctionCall(
|
| + UMAWebBluetoothFunction::SERVICE_GET_CHARACTERISTICS);
|
| +
|
| String characteristicUUID =
|
| BluetoothUUID::getCharacteristic(characteristic, exceptionState);
|
| if (exceptionState.hadException())
|
| @@ -116,6 +123,9 @@ ScriptPromise BluetoothRemoteGATTService::getCharacteristics(
|
| ScriptPromise BluetoothRemoteGATTService::getCharacteristics(
|
| ScriptState* scriptState,
|
| ExceptionState&) {
|
| + RecordWebBluetoothFunctionCall(
|
| + UMAWebBluetoothFunction::SERVICE_GET_CHARACTERISTICS);
|
| +
|
| return GetCharacteristicsImpl(
|
| scriptState, mojom::blink::WebBluetoothGATTQueryQuantity::MULTIPLE);
|
| }
|
|
|