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

Side by Side Diff: content/browser/bluetooth/bluetooth_metrics.cc

Issue 2458163003: Add UMA for WebBluetooth RSSI signal strength level (Closed)
Patch Set: address comments Created 4 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « content/browser/bluetooth/bluetooth_metrics.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/bluetooth/bluetooth_metrics.h" 5 #include "content/browser/bluetooth/bluetooth_metrics.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 "Bluetooth.Web.Characteristic.StartNotifications.Outcome", 321 "Bluetooth.Web.Characteristic.StartNotifications.Outcome",
322 static_cast<int>(outcome), 322 static_cast<int>(outcome),
323 static_cast<int>(UMAGATTOperationOutcome::COUNT)); 323 static_cast<int>(UMAGATTOperationOutcome::COUNT));
324 } 324 }
325 325
326 void RecordStartNotificationsOutcome(CacheQueryOutcome outcome) { 326 void RecordStartNotificationsOutcome(CacheQueryOutcome outcome) {
327 RecordStartNotificationsOutcome( 327 RecordStartNotificationsOutcome(
328 TranslateCacheQueryOutcomeToGATTOperationOutcome(outcome)); 328 TranslateCacheQueryOutcomeToGATTOperationOutcome(outcome));
329 } 329 }
330 330
331 void RecordRSSISignalStrength(int rssi) {
332 UMA_HISTOGRAM_SPARSE_SLOWLY("Bluetooth.Web.RequestDevice.RSSISignalStrength",
333 rssi);
334 }
335
336 void RecordRSSISignalStrengthLevel(UMARSSISignalStrengthLevel level) {
337 UMA_HISTOGRAM_ENUMERATION(
338 "Bluetooth.Web.RequestDevice.RSSISignalStrengthLevel",
339 static_cast<int>(level),
340 static_cast<int>(UMARSSISignalStrengthLevel::COUNT));
341 }
342
331 } // namespace content 343 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/bluetooth/bluetooth_metrics.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698