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

Unified Diff: components/autofill/core/browser/autofill_metrics.cc

Issue 949323002: Collecting UMA metrics for the UnmaskPrompt. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments 2 Created 5 years, 9 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
Index: components/autofill/core/browser/autofill_metrics.cc
diff --git a/components/autofill/core/browser/autofill_metrics.cc b/components/autofill/core/browser/autofill_metrics.cc
index c016c6bcec3fc8141e2b67afeef17c01edbba3f4..feff0263762e95cc9792484a16ac23d708d9564d 100644
--- a/components/autofill/core/browser/autofill_metrics.cc
+++ b/components/autofill/core/browser/autofill_metrics.cc
@@ -341,6 +341,39 @@ void AutofillMetrics::LogDialogUiEvent(DialogUiEvent event) {
}
// static
+void AutofillMetrics::LogUnmaskPromptEvent(UnmaskPromptEvent event) {
+ UMA_HISTOGRAM_ENUMERATION("Autofill.UnmaskPrompt.Events", event,
+ NUM_UNMASK_PROMPT_EVENTS);
+}
+
+// static
+void AutofillMetrics::LogRealPanResult(
+ AutofillClient::GetRealPanResult result) {
+ GetRealPanResult metricResult;
Ilya Sherman 2015/03/19 00:16:01 nit: hacker_case
+ switch (result) {
+ case AutofillClient::SUCCESS: {
+ metricResult = GET_REAL_PAN_RESULT_SUCCESS;
+ break;
+ }
Ilya Sherman 2015/03/19 00:16:01 nit: No need for curly braces.
+ case AutofillClient::TRY_AGAIN_FAILURE: {
+ metricResult = GET_REAL_PAN_RESULT_TRY_AGAIN_FAILURE;
+ break;
+ }
+ case AutofillClient::PERMANENT_FAILURE: {
+ metricResult = GET_REAL_PAN_RESULT_PERMANENT_FAILURE;
+ break;
+ }
+ case AutofillClient::NETWORK_ERROR: {
+ metricResult = GET_REAL_PAN_RESULT_NETWORK_ERROR;
+ break;
+ }
+ }
+ UMA_HISTOGRAM_ENUMERATION("Autofill.UnmaskPrompt.GetRealPanResult",
+ metricResult,
+ NUM_GET_REAL_PAN_RESULTS);
+}
+
+// static
void AutofillMetrics::LogWalletErrorMetric(WalletErrorMetric metric) {
UMA_HISTOGRAM_ENUMERATION("RequestAutocomplete.WalletErrors", metric,
NUM_WALLET_ERROR_METRICS);

Powered by Google App Engine
This is Rietveld 408576698