Chromium Code Reviews| Index: components/page_load_metrics/browser/metrics_web_contents_observer.h |
| diff --git a/components/page_load_metrics/browser/metrics_web_contents_observer.h b/components/page_load_metrics/browser/metrics_web_contents_observer.h |
| index 3dd626b14bb32f52ca67f0807efbf61a990e0dd0..f53e30f1a5a6edc5beb5de0e8a59709e3de98be7 100644 |
| --- a/components/page_load_metrics/browser/metrics_web_contents_observer.h |
| +++ b/components/page_load_metrics/browser/metrics_web_contents_observer.h |
| @@ -116,20 +116,24 @@ class PageLoadTracker { |
| base::TimeTicks abort_time() const { return abort_time_; } |
| void AddObserver(scoped_ptr<PageLoadMetricsObserver> observer); |
| // If the user performs some abort-like action while we are tracking this page |
| // load, notify the tracker. Note that we may not classify this as an abort if |
| // we've already performed a first paint. |
| void NotifyAbort(UserAbortType abort_type, const base::TimeTicks& timestamp); |
| void UpdateAbort(UserAbortType abort_type, const base::TimeTicks& timestamp); |
| + void set_is_using_lofi(bool is_using_lofi); |
| + void set_was_fetched_via_data_reduction_proxy( |
| + bool was_fetched_via_data_reduction_proxy); |
| + |
| private: |
| PageLoadExtraInfo GetPageLoadMetricsInfo(); |
| // Only valid to call post-commit. |
| const GURL& committed_url(); |
| void RecordTimingHistograms(const PageLoadExtraInfo& info); |
| void UpdateAbortInternal(UserAbortType abort_type, |
| const base::TimeTicks& timestamp); |
| // Whether the renderer should be sending timing IPCs to this page load. |
| @@ -155,20 +159,23 @@ class PageLoadTracker { |
| base::TimeTicks foreground_time_; |
| bool started_in_foreground_; |
| PageLoadTiming timing_; |
| // Interface to chrome features. Must outlive the class. |
| PageLoadMetricsEmbedderInterface* const embedder_interface_; |
| std::vector<scoped_ptr<PageLoadMetricsObserver>> observers_; |
| + bool is_using_lofi_; |
|
bengr
2016/02/26 22:53:57
Add comments.
RyanSturm
2016/03/01 19:36:04
Done.
|
| + bool was_fetched_via_data_reduction_proxy_; |
| + |
| DISALLOW_COPY_AND_ASSIGN(PageLoadTracker); |
| }; |
| // MetricsWebContentsObserver tracks page loads and loading metrics |
| // related data based on IPC messages received from a |
| // MetricsRenderFrameObserver. |
| class MetricsWebContentsObserver |
| : public content::WebContentsObserver, |
| public content::WebContentsUserData<MetricsWebContentsObserver> { |
| public: |