Index: chrome/browser/predictors/resource_prefetch_predictor.h |
diff --git a/chrome/browser/predictors/resource_prefetch_predictor.h b/chrome/browser/predictors/resource_prefetch_predictor.h |
index cec2207d48f5d4d8e62642162e41a75cbbbdb7e7..c09b02433fcdfc3a3d3d29a3d7697264d6d2410a 100644 |
--- a/chrome/browser/predictors/resource_prefetch_predictor.h |
+++ b/chrome/browser/predictors/resource_prefetch_predictor.h |
@@ -114,6 +114,8 @@ class ResourcePrefetchPredictor |
GURL resource_url; |
content::ResourceType resource_type; |
net::RequestPriority priority; |
+ base::TimeTicks response_time; |
+ bool before_first_contentful_paint; |
// Only for responses. |
std::string mime_type; |
@@ -138,6 +140,7 @@ class ResourcePrefetchPredictor |
GURL main_frame_url; |
GURL initial_url; |
+ base::TimeTicks first_contentful_paint; |
// Stores all subresource requests within a single navigation, from initial |
// main frame request to navigation completion. |
@@ -205,6 +208,11 @@ class ResourcePrefetchPredictor |
// Called when the main frame of a page completes loading. |
void RecordMainFrameLoadComplete(const NavigationID& navigation_id); |
+ // Called after the main frame's first contentful paint. |
+ void RecordFirstContentfulPaint( |
+ const NavigationID& navigation_id, |
+ const base::TimeTicks& first_contentful_paint); |
+ |
// Starts prefetching if it is enabled for |origin| and prefetching data |
// exists for the |main_frame_url| either at the URL or at the host level. |
void StartPrefetching(const GURL& main_frame_url, PrefetchOrigin origin); |