| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #ifndef CHROME_BROWSER_PROFILES_PROFILE_METRICS_H_ | 5 #ifndef CHROME_BROWSER_PROFILES_PROFILE_METRICS_H_ |
| 6 #define CHROME_BROWSER_PROFILES_PROFILE_METRICS_H_ | 6 #define CHROME_BROWSER_PROFILES_PROFILE_METRICS_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 PROFILE_AVATAR_MENU_UPGRADE_NOT_YOU, | 174 PROFILE_AVATAR_MENU_UPGRADE_NOT_YOU, |
| 175 NUM_PROFILE_AVATAR_MENU_UPGRADE_METRICS, | 175 NUM_PROFILE_AVATAR_MENU_UPGRADE_METRICS, |
| 176 }; | 176 }; |
| 177 | 177 |
| 178 static void UpdateReportedProfilesStatistics(ProfileManager* manager); | 178 static void UpdateReportedProfilesStatistics(ProfileManager* manager); |
| 179 // Count and return summary information about the profiles currently in the | 179 // Count and return summary information about the profiles currently in the |
| 180 // |manager|. This information is returned in the output variable |counts|. | 180 // |manager|. This information is returned in the output variable |counts|. |
| 181 static bool CountProfileInformation(ProfileManager* manager, | 181 static bool CountProfileInformation(ProfileManager* manager, |
| 182 ProfileCounts* counts); | 182 ProfileCounts* counts); |
| 183 | 183 |
| 184 #if defined(OS_WIN) || defined(OS_MACOSX) |
| 185 // Update OS level tracking of profile counts. |
| 186 static void UpdateReportedOSProfileStatistics(int active, int signedin); |
| 187 #endif |
| 188 |
| 184 static void LogNumberOfProfiles(ProfileManager* manager); | 189 static void LogNumberOfProfiles(ProfileManager* manager); |
| 185 static void LogProfileAddNewUser(ProfileAdd metric); | 190 static void LogProfileAddNewUser(ProfileAdd metric); |
| 186 static void LogProfileAvatarSelection(size_t icon_index); | 191 static void LogProfileAvatarSelection(size_t icon_index); |
| 187 static void LogProfileDeleteUser(ProfileDelete metric); | 192 static void LogProfileDeleteUser(ProfileDelete metric); |
| 188 static void LogProfileOpenMethod(ProfileOpen metric); | 193 static void LogProfileOpenMethod(ProfileOpen metric); |
| 189 static void LogProfileSwitchGaia(ProfileGaia metric); | 194 static void LogProfileSwitchGaia(ProfileGaia metric); |
| 190 static void LogProfileSwitchUser(ProfileOpen metric); | 195 static void LogProfileSwitchUser(ProfileOpen metric); |
| 191 static void LogProfileSyncInfo(ProfileSync metric); | 196 static void LogProfileSyncInfo(ProfileSync metric); |
| 192 static void LogProfileAuthResult(ProfileAuth metric); | 197 static void LogProfileAuthResult(ProfileAuth metric); |
| 193 static void LogProfileDesktopMenu(ProfileDesktopMenu metric, | 198 static void LogProfileDesktopMenu(ProfileDesktopMenu metric, |
| (...skipping 12 matching lines...) Expand all Loading... |
| 206 | 211 |
| 207 // These functions should only be called on the UI thread because they hook | 212 // These functions should only be called on the UI thread because they hook |
| 208 // into g_browser_process through a helper function. | 213 // into g_browser_process through a helper function. |
| 209 static void LogProfileLaunch(Profile* profile); | 214 static void LogProfileLaunch(Profile* profile); |
| 210 static void LogProfileSyncSignIn(const base::FilePath& profile_path); | 215 static void LogProfileSyncSignIn(const base::FilePath& profile_path); |
| 211 static void LogProfileUpdate(const base::FilePath& profile_path); | 216 static void LogProfileUpdate(const base::FilePath& profile_path); |
| 212 }; | 217 }; |
| 213 | 218 |
| 214 | 219 |
| 215 #endif // CHROME_BROWSER_PROFILES_PROFILE_METRICS_H_ | 220 #endif // CHROME_BROWSER_PROFILES_PROFILE_METRICS_H_ |
| OLD | NEW |