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

Unified Diff: content/browser/frame_host/navigation_handle_impl.cc

Issue 2132603002: [page_load_metrics] Add a NavigationThrottle for richer abort metrics (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nasko@ nits Created 4 years, 4 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: content/browser/frame_host/navigation_handle_impl.cc
diff --git a/content/browser/frame_host/navigation_handle_impl.cc b/content/browser/frame_host/navigation_handle_impl.cc
index 47dc9a23962c4e42ceaede2f50cd7418f4283fe0..0bc1ceb31c46c5a8bc6cfa7f0cd1684ed024c000 100644
--- a/content/browser/frame_host/navigation_handle_impl.cc
+++ b/content/browser/frame_host/navigation_handle_impl.cc
@@ -552,15 +552,16 @@ void NavigationHandleImpl::RegisterNavigationThrottles() {
// RegisterThrottleForTesting.
ScopedVector<NavigationThrottle> throttles_to_register =
GetContentClient()->browser()->CreateThrottlesForNavigation(this);
+ std::unique_ptr<NavigationThrottle> devtools_throttle =
+ RenderFrameDevToolsAgentHost::CreateThrottleForNavigation(this);
+ if (devtools_throttle)
+ throttles_to_register.push_back(devtools_throttle.release());
+
if (throttles_to_register.size() > 0) {
- throttles_.insert(throttles_.end(), throttles_to_register.begin(),
+ throttles_.insert(throttles_.begin(), throttles_to_register.begin(),
throttles_to_register.end());
throttles_to_register.weak_clear();
}
- std::unique_ptr<NavigationThrottle> devtools_throttle =
- RenderFrameDevToolsAgentHost::CreateThrottleForNavigation(this);
- if (devtools_throttle)
- throttles_.push_back(devtools_throttle.release());
}
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698