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

Unified Diff: content/browser/bluetooth/bluetooth_metrics.cc

Issue 1334763002: bluetooth: Subscribe to notifications (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bluetooth-origin
Patch Set: Fix global interface test Created 5 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 | « content/browser/bluetooth/bluetooth_metrics.h ('k') | content/common/bluetooth/bluetooth_messages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/bluetooth/bluetooth_metrics.cc
diff --git a/content/browser/bluetooth/bluetooth_metrics.cc b/content/browser/bluetooth/bluetooth_metrics.cc
index e04a7cab0ea54ac3730cd60be9c1541c3e148412..e9a34c82ad9e2912e0e44609ed87a224e4116337 100644
--- a/content/browser/bluetooth/bluetooth_metrics.cc
+++ b/content/browser/bluetooth/bluetooth_metrics.cc
@@ -150,6 +150,9 @@ void RecordGATTOperationOutcome(UMAGATTOperation operation,
case UMAGATTOperation::CHARACTERISTIC_WRITE:
RecordCharacteristicWriteValueOutcome(outcome);
return;
+ case UMAGATTOperation::START_NOTIFICATIONS:
+ RecordStartNotificationsOutcome(outcome);
+ return;
case UMAGATTOperation::COUNT:
NOTREACHED();
return;
@@ -174,4 +177,12 @@ void RecordCharacteristicWriteValueOutcome(UMAGATTOperationOutcome outcome) {
static_cast<int>(UMAGATTOperationOutcome::COUNT));
}
+// Characteristic.startNotifications
+void RecordStartNotificationsOutcome(UMAGATTOperationOutcome outcome) {
+ UMA_HISTOGRAM_ENUMERATION(
+ "Bluetooth.Web.Characteristic.StartNotifications.Outcome",
+ static_cast<int>(outcome),
+ static_cast<int>(UMAGATTOperationOutcome::COUNT));
+}
+
} // namespace content
« no previous file with comments | « content/browser/bluetooth/bluetooth_metrics.h ('k') | content/common/bluetooth/bluetooth_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698