Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CONTENT_RENDERER_MEDIA_WEBRTC_UMA_HISTOGRAMS_H_ | |
| 6 #define CONTENT_RENDERER_MEDIA_WEBRTC_UMA_HISTOGRAMS_H_ | |
| 7 | |
| 8 #include "base/metrics/histogram.h" | |
| 9 | |
| 10 namespace { | |
| 11 | |
| 12 // Helper enum used for histogramming calls to WebRTC APIs from JavaScript. | |
| 13 enum JavaScriptAPIName { | |
| 14 kWebkitGetUserMedia, | |
|
tommi (sloooow) - chröme
2012/09/12 13:10:24
follow chrome style
perkj_chrome
2012/09/12 13:54:39
Done.
| |
| 15 kWebkitPeerConnection, | |
| 16 kInvalidName | |
| 17 }; | |
| 18 | |
| 19 // Helper method used to collect information about the number of times | |
| 20 // different WebRTC API:s are called from JavaScript. | |
| 21 // The histogram can be viewed at chrome://histograms/WebRTC.webkitApiCount. | |
| 22 void UpdateWebRTCMethodCount(JavaScriptAPIName api_name) { | |
| 23 UMA_HISTOGRAM_ENUMERATION("WebRTC.webkitApiCount", api_name, kInvalidName); | |
| 24 } | |
| 25 | |
| 26 } // namespace | |
| 27 | |
| 28 #endif // CONTENT_RENDERER_MEDIA_WEBRTC_UMA_HISTOGRAMS_H_ | |
| OLD | NEW |