Skip to content

Commit

Permalink
Record chrome's startup time, to be used in future retention experiments
Browse files Browse the repository at this point in the history
- For windows in the registry
- not implemented for posix

BUG=32474
TEST=none


Review URL: http://codereview.chromium.org/558009

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37360 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
cpu@chromium.org committed Jan 28, 2010
1 parent 5febad2 commit fc09792
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
2 changes: 2 additions & 0 deletions chrome/browser/browser_main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -978,6 +978,8 @@ int BrowserMain(const MainFunctionParams& parameters) {
// the main message loop.
if (browser_init.Start(parsed_command_line, std::wstring(), profile,
&result_code)) {
// Record now as the last succesful chrome start.
GoogleUpdateSettings::SetLastRunTime();
// Call Recycle() here as late as possible, before going into the loop
// because Start() will add things to it while creating the main window.
if (pool)
Expand Down
14 changes: 14 additions & 0 deletions chrome/browser/google_update_settings_posix.cc
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,17 @@ bool GoogleUpdateSettings::SetMetricsId(const std::wstring& client_id) {
google_update::posix_guid = WideToASCII(client_id);
return GoogleUpdateSettings::SetCollectStatsConsent(true);
}

// GetLastRunTime and SetLastRunTime are not implemented for posix. Their
// currebnt return values signal failure which the caller is designed to
// handle.

// static
int GoogleUpdateSettings::GetLastRunTime() {
return -1;
}

// static
bool GoogleUpdateSettings::SetLastRunTime() {
return false;
}

0 comments on commit fc09792

Please sign in to comment.