OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "chrome/browser/profiles/profile_metrics.h" | 5 #include "chrome/browser/profiles/profile_metrics.h" |
6 | 6 |
7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
10 #include "chrome/browser/browser_process.h" | 10 #include "chrome/browser/browser_process.h" |
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
355 UMA_HISTOGRAM_ENUMERATION("Profile.DesktopMenu.GAIAReAuth", metric, | 355 UMA_HISTOGRAM_ENUMERATION("Profile.DesktopMenu.GAIAReAuth", metric, |
356 NUM_PROFILE_DESKTOP_MENU_METRICS); | 356 NUM_PROFILE_DESKTOP_MENU_METRICS); |
357 break; | 357 break; |
358 case signin::GAIA_SERVICE_TYPE_DEFAULT: | 358 case signin::GAIA_SERVICE_TYPE_DEFAULT: |
359 UMA_HISTOGRAM_ENUMERATION("Profile.DesktopMenu.GAIADefault", metric, | 359 UMA_HISTOGRAM_ENUMERATION("Profile.DesktopMenu.GAIADefault", metric, |
360 NUM_PROFILE_DESKTOP_MENU_METRICS); | 360 NUM_PROFILE_DESKTOP_MENU_METRICS); |
361 break; | 361 break; |
362 } | 362 } |
363 } | 363 } |
364 | 364 |
| 365 void ProfileMetrics::LogProfileDelete(bool profile_was_signed_in) { |
| 366 UMA_HISTOGRAM_BOOLEAN("Profile.Delete", profile_was_signed_in); |
| 367 } |
| 368 |
365 #if defined(OS_ANDROID) | 369 #if defined(OS_ANDROID) |
366 void ProfileMetrics::LogProfileAndroidAccountManagementMenu( | 370 void ProfileMetrics::LogProfileAndroidAccountManagementMenu( |
367 ProfileAndroidAccountManagementMenu metric, | 371 ProfileAndroidAccountManagementMenu metric, |
368 signin::GAIAServiceType gaia_service) { | 372 signin::GAIAServiceType gaia_service) { |
369 // The first parameter to the histogram needs to be literal, because of the | 373 // The first parameter to the histogram needs to be literal, because of the |
370 // optimized implementation of |UMA_HISTOGRAM_ENUMERATION|. Do not attempt | 374 // optimized implementation of |UMA_HISTOGRAM_ENUMERATION|. Do not attempt |
371 // to refactor. | 375 // to refactor. |
372 switch (gaia_service) { | 376 switch (gaia_service) { |
373 case signin::GAIA_SERVICE_TYPE_NONE: | 377 case signin::GAIA_SERVICE_TYPE_NONE: |
374 UMA_HISTOGRAM_ENUMERATION( | 378 UMA_HISTOGRAM_ENUMERATION( |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
426 UMA_HISTOGRAM_ENUMERATION("Profile.SyncSignIn", | 430 UMA_HISTOGRAM_ENUMERATION("Profile.SyncSignIn", |
427 GetProfileType(profile_path), | 431 GetProfileType(profile_path), |
428 NUM_PROFILE_TYPE_METRICS); | 432 NUM_PROFILE_TYPE_METRICS); |
429 } | 433 } |
430 | 434 |
431 void ProfileMetrics::LogProfileUpdate(const base::FilePath& profile_path) { | 435 void ProfileMetrics::LogProfileUpdate(const base::FilePath& profile_path) { |
432 UMA_HISTOGRAM_ENUMERATION("Profile.Update", | 436 UMA_HISTOGRAM_ENUMERATION("Profile.Update", |
433 GetProfileType(profile_path), | 437 GetProfileType(profile_path), |
434 NUM_PROFILE_TYPE_METRICS); | 438 NUM_PROFILE_TYPE_METRICS); |
435 } | 439 } |
OLD | NEW |