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

Side by Side Diff: chrome/renderer/page_load_histograms.h

Issue 63273002: Rename WebKit namespace to blink (part 4) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/renderer/net_benchmarking_extension.cc ('k') | chrome/renderer/page_load_histograms.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_RENDERER_PAGE_LOAD_HISTOGRAMS_H_ 5 #ifndef CHROME_RENDERER_PAGE_LOAD_HISTOGRAMS_H_
6 #define CHROME_RENDERER_PAGE_LOAD_HISTOGRAMS_H_ 6 #define CHROME_RENDERER_PAGE_LOAD_HISTOGRAMS_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "content/public/renderer/render_view_observer.h" 9 #include "content/public/renderer/render_view_observer.h"
10 10
11 namespace content { 11 namespace content {
12 class DocumentState; 12 class DocumentState;
13 } 13 }
14 14
15 class PageLoadHistograms : public content::RenderViewObserver { 15 class PageLoadHistograms : public content::RenderViewObserver {
16 public: 16 public:
17 explicit PageLoadHistograms(content::RenderView* render_view); 17 explicit PageLoadHistograms(content::RenderView* render_view);
18 18
19 private: 19 private:
20 // RenderViewObserver implementation. 20 // RenderViewObserver implementation.
21 virtual void FrameWillClose(WebKit::WebFrame* frame) OVERRIDE; 21 virtual void FrameWillClose(blink::WebFrame* frame) OVERRIDE;
22 virtual void ClosePage() OVERRIDE; 22 virtual void ClosePage() OVERRIDE;
23 23
24 // Dump all page load histograms appropriate for the given frame. 24 // Dump all page load histograms appropriate for the given frame.
25 // 25 //
26 // This method will only dump once-per-instance, so it is safe to call 26 // This method will only dump once-per-instance, so it is safe to call
27 // multiple times. 27 // multiple times.
28 // 28 //
29 // The time points we keep are 29 // The time points we keep are
30 // request: time document was requested by user 30 // request: time document was requested by user
31 // start: time load of document started 31 // start: time load of document started
32 // commit: time load of document started 32 // commit: time load of document started
33 // finish_document: main document loaded, before onload() 33 // finish_document: main document loaded, before onload()
34 // finish_all_loads: after onload() and all resources are loaded 34 // finish_all_loads: after onload() and all resources are loaded
35 // first_paint: first paint performed 35 // first_paint: first paint performed
36 // first_paint_after_load: first paint performed after load is finished 36 // first_paint_after_load: first paint performed after load is finished
37 // begin: request if it was user requested, start otherwise 37 // begin: request if it was user requested, start otherwise
38 // 38 //
39 // It's possible for the request time not to be set, if a client 39 // It's possible for the request time not to be set, if a client
40 // redirect had been done (the user never requested the page) 40 // redirect had been done (the user never requested the page)
41 // Also, it's possible to load a page without ever laying it out 41 // Also, it's possible to load a page without ever laying it out
42 // so first_paint and first_paint_after_load can be 0. 42 // so first_paint and first_paint_after_load can be 0.
43 void Dump(WebKit::WebFrame* frame); 43 void Dump(blink::WebFrame* frame);
44 44
45 void ResetCrossFramePropertyAccess(); 45 void ResetCrossFramePropertyAccess();
46 46
47 void LogPageLoadTime(const content::DocumentState* load_times, 47 void LogPageLoadTime(const content::DocumentState* load_times,
48 const WebKit::WebDataSource* ds) const; 48 const blink::WebDataSource* ds) const;
49 49
50 // Site isolation metric counts. 50 // Site isolation metric counts.
51 // These are per-page-load counts, reset to 0 after they are dumped. 51 // These are per-page-load counts, reset to 0 after they are dumped.
52 int cross_origin_access_count_; 52 int cross_origin_access_count_;
53 int same_origin_access_count_; 53 int same_origin_access_count_;
54 54
55 DISALLOW_COPY_AND_ASSIGN(PageLoadHistograms); 55 DISALLOW_COPY_AND_ASSIGN(PageLoadHistograms);
56 }; 56 };
57 57
58 #endif // CHROME_RENDERER_PAGE_LOAD_HISTOGRAMS_H_ 58 #endif // CHROME_RENDERER_PAGE_LOAD_HISTOGRAMS_H_
OLDNEW
« no previous file with comments | « chrome/renderer/net_benchmarking_extension.cc ('k') | chrome/renderer/page_load_histograms.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698