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

Side by Side Diff: components/startup_metric_utils/browser/startup_metric_utils.h

Issue 2345933002: Break chrome_initial's dependence on //components/startup_metric_utils/browser:lib (Closed)
Patch Set: fdoray feedback Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 COMPONENTS_STARTUP_METRIC_UTILS_BROWSER_STARTUP_METRIC_UTILS_H_ 5 #ifndef COMPONENTS_STARTUP_METRIC_UTILS_BROWSER_STARTUP_METRIC_UTILS_H_
6 #define COMPONENTS_STARTUP_METRIC_UTILS_BROWSER_STARTUP_METRIC_UTILS_H_ 6 #define COMPONENTS_STARTUP_METRIC_UTILS_BROWSER_STARTUP_METRIC_UTILS_H_
7 7
8 #include "base/time/time.h" 8 #include "base/time/time.h"
9 9
10 class PrefRegistrySimple; 10 class PrefRegistrySimple;
(...skipping 27 matching lines...) Expand all
38 void RecordStartupProcessCreationTime(const base::Time& time); 38 void RecordStartupProcessCreationTime(const base::Time& time);
39 39
40 // Call this with a time recorded as early as possible in the startup process. 40 // Call this with a time recorded as early as possible in the startup process.
41 // On Android, the entry point time is the time at which the Java code starts. 41 // On Android, the entry point time is the time at which the Java code starts.
42 // In Mojo, the entry point time is the time at which the shell starts. 42 // In Mojo, the entry point time is the time at which the shell starts.
43 void RecordMainEntryPointTime(const base::Time& time); 43 void RecordMainEntryPointTime(const base::Time& time);
44 44
45 // Call this with the time when the executable is loaded and main() is entered. 45 // Call this with the time when the executable is loaded and main() is entered.
46 // Can be different from |RecordMainEntryPointTime| when the startup process is 46 // Can be different from |RecordMainEntryPointTime| when the startup process is
47 // contained in a separate dll, such as with chrome.exe / chrome.dll on Windows. 47 // contained in a separate dll, such as with chrome.exe / chrome.dll on Windows.
48 void RecordExeMainEntryPointTime(const base::Time& time); 48 void RecordExeMainEntryPointTicks(const base::TimeTicks& time);
grt (UTC plus 2) 2016/09/20 19:20:27 I left this as const-ref for consistency with the
49 49
50 // Call this with the time recorded just before the message loop is started. 50 // Call this with the time recorded just before the message loop is started.
51 // |is_first_run| - is the current launch part of a first run. |pref_service| is 51 // |is_first_run| - is the current launch part of a first run. |pref_service| is
52 // used to store state for stats that span multiple startups. 52 // used to store state for stats that span multiple startups.
53 void RecordBrowserMainMessageLoopStart(const base::TimeTicks& ticks, 53 void RecordBrowserMainMessageLoopStart(const base::TimeTicks& ticks,
54 bool is_first_run, 54 bool is_first_run,
55 PrefService* pref_service); 55 PrefService* pref_service);
56 56
57 // Call this with the time when the first browser window became visible. 57 // Call this with the time when the first browser window became visible.
58 void RecordBrowserWindowDisplay(const base::TimeTicks& ticks); 58 void RecordBrowserWindowDisplay(const base::TimeTicks& ticks);
(...skipping 24 matching lines...) Expand all
83 void RecordFirstWebContentsMainNavigationFinished(const base::TimeTicks& ticks); 83 void RecordFirstWebContentsMainNavigationFinished(const base::TimeTicks& ticks);
84 84
85 // Returns the TimeTicks corresponding to main entry as recorded by 85 // Returns the TimeTicks corresponding to main entry as recorded by
86 // RecordMainEntryPointTime. Returns a null TimeTicks if a value has not been 86 // RecordMainEntryPointTime. Returns a null TimeTicks if a value has not been
87 // recorded yet. This method is expected to be called from the UI thread. 87 // recorded yet. This method is expected to be called from the UI thread.
88 base::TimeTicks MainEntryPointTicks(); 88 base::TimeTicks MainEntryPointTicks();
89 89
90 } // namespace startup_metric_utils 90 } // namespace startup_metric_utils
91 91
92 #endif // COMPONENTS_STARTUP_METRIC_UTILS_BROWSER_STARTUP_METRIC_UTILS_H_ 92 #endif // COMPONENTS_STARTUP_METRIC_UTILS_BROWSER_STARTUP_METRIC_UTILS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698