diff options
author | rlp@chromium.org <rlp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-12-12 21:53:57 +0000 |
---|---|---|
committer | rlp@chromium.org <rlp@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-12-12 21:53:57 +0000 |
commit | a7be698679e55d0f3dea967dc40755bc7f369915 (patch) | |
tree | 0de949f2f138ce02b976439a744c1f386c306073 /chrome/browser/profiles/profile_manager.cc | |
parent | ec99c3352fdec4248da487b91f6cc52ddd74fd5a (diff) | |
download | chromium_src-a7be698679e55d0f3dea967dc40755bc7f369915.zip chromium_src-a7be698679e55d0f3dea967dc40755bc7f369915.tar.gz chromium_src-a7be698679e55d0f3dea967dc40755bc7f369915.tar.bz2 |
Adding metrics to track browser launches per primary/secondary profile. Adding metrics to track number of profiles per machine.
BUG=160771,106774
TEST=none
Review URL: http://codereview.chromium.org/8890054
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@114088 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/profiles/profile_manager.cc')
-rw-r--r-- | chrome/browser/profiles/profile_manager.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/chrome/browser/profiles/profile_manager.cc b/chrome/browser/profiles/profile_manager.cc index 1a4f6f9..509c842 100644 --- a/chrome/browser/profiles/profile_manager.cc +++ b/chrome/browser/profiles/profile_manager.cc @@ -20,6 +20,7 @@ #include "chrome/browser/prefs/pref_service.h" #include "chrome/browser/prefs/scoped_user_pref_update.h" #include "chrome/browser/profiles/profile_info_cache.h" +#include "chrome/browser/profiles/profile_metrics.h" #include "chrome/browser/sessions/session_service_factory.h" #include "chrome/browser/sync/profile_sync_service.h" #include "chrome/browser/ui/browser.h" @@ -370,6 +371,7 @@ bool ProfileManager::AddProfile(Profile* profile) { RegisterProfile(profile, true); DoFinalInit(profile, ShouldGoOffTheRecord()); + ProfileMetrics::LogNumberOfProfiles(this, ProfileMetrics::ADD_PROFILE_EVENT); return true; } @@ -659,6 +661,9 @@ void ProfileManager::ScheduleProfileForDeletion(const FilePath& profile_dir) { QueueProfileDirectoryForDeletion(profile_dir); cache.DeleteProfileFromCache(profile_dir); + + ProfileMetrics::LogNumberOfProfiles(this, + ProfileMetrics::DELETE_PROFILE_EVENT); } // static @@ -681,6 +686,8 @@ void ProfileManager::AutoloadProfiles() { GetProfile(cache.GetPathOfProfileAtIndex(p)); } } + ProfileMetrics::LogNumberOfProfiles(this, + ProfileMetrics::STARTUP_PROFILE_EVENT); } ProfileManagerWithoutInit::ProfileManagerWithoutInit( |