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

Unified Diff: chrome/browser/prerender/prerender_tab_helper.h

Issue 2738783002: Prerender: Remove PerceivedPLT histograms (Closed)
Patch Set: set the origin in prerender_tab_helper Created 3 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
« no previous file with comments | « chrome/browser/prerender/prerender_manager.cc ('k') | chrome/browser/prerender/prerender_tab_helper.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/prerender/prerender_tab_helper.h
diff --git a/chrome/browser/prerender/prerender_tab_helper.h b/chrome/browser/prerender/prerender_tab_helper.h
index f944aa10b13abcaa113d173514ab49ed52dafaf6..1686f49679987547b7fe21e6eca3916431321539 100644
--- a/chrome/browser/prerender/prerender_tab_helper.h
+++ b/chrome/browser/prerender/prerender_tab_helper.h
@@ -20,8 +20,8 @@ namespace prerender {
class PrerenderManager;
-// PrerenderTabHelper is responsible for recording perceived pageload times
-// to compare PLT's with prerendering enabled and disabled.
+// Notifies the PrerenderManager with the events happening in the prerendered
+// WebContents.
class PrerenderTabHelper
: public content::WebContentsObserver,
public content::WebContentsUserData<PrerenderTabHelper> {
@@ -31,7 +31,6 @@ class PrerenderTabHelper
// content::WebContentsObserver implementation.
void DidGetRedirectForResourceRequest(
const content::ResourceRedirectDetails& details) override;
- void DidStopLoading() override;
void DidStartNavigation(
content::NavigationHandle* navigation_handle) override;
void DidFinishNavigation(
@@ -52,10 +51,6 @@ class PrerenderTabHelper
explicit PrerenderTabHelper(content::WebContents* web_contents);
friend class content::WebContentsUserData<PrerenderTabHelper>;
- void RecordPerceivedPageLoadTime(
- base::TimeDelta perceived_page_load_time,
- double fraction_plt_elapsed_at_swap_in);
-
// Retrieves the PrerenderManager, or NULL, if none was found.
PrerenderManager* MaybeGetPrerenderManager() const;
@@ -67,27 +62,11 @@ class PrerenderTabHelper
// Returns whether the WebContents being observed is currently prerendering.
bool IsPrerendering();
- // The type the current pending navigation, if there is one. If the tab is a
- // prerender before swap, the value is always NAVIGATION_TYPE_PRERENDERED,
- // even if the prerender is not currently loading.
- NavigationType navigation_type_;
-
- // If |navigation_type_| is not NAVIGATION_TYPE_NORMAL, the origin of the
- // relevant prerender. Otherwise, ORIGIN_NONE.
+ // The origin of the relevant prerender or ORIGIN_NONE if there is no
+ // prerender associated with the WebContents.
Origin origin_;
- // System time at which the current load was started for the purpose of
- // the perceived page load time (PPLT). If null, there is no current
- // load.
- base::TimeTicks pplt_load_start_;
-
- // System time at which the actual pageload started (pre-swapin), if
- // a applicable (in cases when a prerender that was still loading was
- // swapped in).
- base::TimeTicks actual_load_start_;
-
- // Record the most recent swap time. This differs from |pplt_load_start_| in
- // that it is not reset in various circumstances, like a load being stopped.
+ // Record the most recent swap time.
base::TimeTicks swap_ticks_;
// Current URL being loaded.
« no previous file with comments | « chrome/browser/prerender/prerender_manager.cc ('k') | chrome/browser/prerender/prerender_tab_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698