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

Unified Diff: chrome/browser/profiles/profile_metrics.cc

Issue 304983005: [Android][Mirror] UMA stats for Account management screen. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase. Created 6 years, 7 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 | « chrome/browser/profiles/profile_metrics.h ('k') | chrome/browser/signin/signin_header_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/profiles/profile_metrics.cc
diff --git a/chrome/browser/profiles/profile_metrics.cc b/chrome/browser/profiles/profile_metrics.cc
index 66211dd8a739f7d1fa4cf20207c4f832dd168c15..7e72ad6474ac5298e5098cc8444fdfc410389746 100644
--- a/chrome/browser/profiles/profile_metrics.cc
+++ b/chrome/browser/profiles/profile_metrics.cc
@@ -330,6 +330,54 @@ void ProfileMetrics::LogProfileDesktopMenu(
}
}
+#if defined(OS_ANDROID)
+void ProfileMetrics::LogProfileAndroidAccountManagementMenu(
+ ProfileAndroidAccountManagementMenu metric,
+ signin::GAIAServiceType gaia_service) {
+ // The first parameter to the histogram needs to be literal, because of the
+ // optimized implementation of |UMA_HISTOGRAM_ENUMERATION|. Do not attempt
+ // to refactor.
+ switch (gaia_service) {
+ case signin::GAIA_SERVICE_TYPE_NONE:
+ UMA_HISTOGRAM_ENUMERATION(
+ "Profile.AndroidAccountManagementMenu.NonGAIA",
+ metric,
+ NUM_PROFILE_ANDROID_ACCOUNT_MANAGEMENT_MENU_METRICS);
+ break;
+ case signin::GAIA_SERVICE_TYPE_SIGNOUT:
+ UMA_HISTOGRAM_ENUMERATION(
+ "Profile.AndroidAccountManagementMenu.GAIASignout",
+ metric,
+ NUM_PROFILE_ANDROID_ACCOUNT_MANAGEMENT_MENU_METRICS);
+ break;
+ case signin::GAIA_SERVICE_TYPE_INCOGNITO:
+ UMA_HISTOGRAM_ENUMERATION(
+ "Profile.AndroidAccountManagementMenu.GAIASignoutIncognito",
+ metric,
+ NUM_PROFILE_ANDROID_ACCOUNT_MANAGEMENT_MENU_METRICS);
+ break;
+ case signin::GAIA_SERVICE_TYPE_ADDSESSION:
+ UMA_HISTOGRAM_ENUMERATION(
+ "Profile.AndroidAccountManagementMenu.GAIAAddSession",
+ metric,
+ NUM_PROFILE_ANDROID_ACCOUNT_MANAGEMENT_MENU_METRICS);
+ break;
+ case signin::GAIA_SERVICE_TYPE_REAUTH:
+ UMA_HISTOGRAM_ENUMERATION(
+ "Profile.AndroidAccountManagementMenu.GAIAReAuth",
+ metric,
+ NUM_PROFILE_ANDROID_ACCOUNT_MANAGEMENT_MENU_METRICS);
+ break;
+ case signin::GAIA_SERVICE_TYPE_DEFAULT:
+ UMA_HISTOGRAM_ENUMERATION(
+ "Profile.AndroidAccountManagementMenu.GAIADefault",
+ metric,
+ NUM_PROFILE_ANDROID_ACCOUNT_MANAGEMENT_MENU_METRICS);
+ break;
+ }
+}
+#endif // defined(OS_ANDROID)
+
void ProfileMetrics::LogProfileLaunch(Profile* profile) {
base::FilePath profile_path = profile->GetPath();
UMA_HISTOGRAM_ENUMERATION("Profile.LaunchBrowser",
« no previous file with comments | « chrome/browser/profiles/profile_metrics.h ('k') | chrome/browser/signin/signin_header_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698