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

Unified Diff: chrome/renderer/searchbox/searchbox.cc

Issue 1007383003: Adds a new UMA histogram to measure the NTP load time since navigation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/searchbox/searchbox.cc
diff --git a/chrome/renderer/searchbox/searchbox.cc b/chrome/renderer/searchbox/searchbox.cc
index d1d71a7ffd9d0d0589fe1d66a6b05e7a81512b77..ca4b28718e61f4a81a9508efd25f3f68e61aa04c 100644
--- a/chrome/renderer/searchbox/searchbox.cc
+++ b/chrome/renderer/searchbox/searchbox.cc
@@ -161,13 +161,10 @@ SearchBox::~SearchBox() {
void SearchBox::LogEvent(NTPLoggingEventType event) {
// navigation_start in ms.
- uint64 start = 1000 *
- render_view()
- ->GetMainRenderFrame()
- ->GetWebFrame()
- ->performance()
kmadhusu 2015/03/17 00:06:29 Did you rebase this CL against crrev.com/100675300
fserb 2015/03/17 16:02:17 yeah. It is on top of the other. I must have forgo
- .navigationStart();
- uint64 now = (base::Time::Now() - base::Time::UnixEpoch()).InMilliseconds();
+ uint64 start = 1000 * (render_view()->GetMainRenderFrame()->
+ GetWebFrame()->performance().navigationStart());
+ uint64 now =
+ (base::TimeTicks::Now() - base::TimeTicks::UnixEpoch()).InMilliseconds();
DCHECK(now >= start);
uint64 delta = now - start;
DVLOG(1) << now << " - " << start << " = " << delta;

Powered by Google App Engine
This is Rietveld 408576698