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

Side by Side Diff: chrome/browser/page_load_metrics/metrics_web_contents_observer.h

Issue 2894973002: Provide WebContents::CreateParams to tab helpers. (Closed)
Patch Set: rebase Created 3 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_BROWSER_PAGE_LOAD_METRICS_METRICS_WEB_CONTENTS_OBSERVER_H_ 5 #ifndef CHROME_BROWSER_PAGE_LOAD_METRICS_METRICS_WEB_CONTENTS_OBSERVER_H_
6 #define CHROME_BROWSER_PAGE_LOAD_METRICS_METRICS_WEB_CONTENTS_OBSERVER_H_ 6 #define CHROME_BROWSER_PAGE_LOAD_METRICS_METRICS_WEB_CONTENTS_OBSERVER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <vector> 10 #include <vector>
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 69
70 private: 70 private:
71 page_load_metrics::MetricsWebContentsObserver* observer_; 71 page_load_metrics::MetricsWebContentsObserver* observer_;
72 72
73 DISALLOW_COPY_AND_ASSIGN(TestingObserver); 73 DISALLOW_COPY_AND_ASSIGN(TestingObserver);
74 }; 74 };
75 75
76 // Note that the returned metrics is owned by the web contents. 76 // Note that the returned metrics is owned by the web contents.
77 static MetricsWebContentsObserver* CreateForWebContents( 77 static MetricsWebContentsObserver* CreateForWebContents(
78 content::WebContents* web_contents, 78 content::WebContents* web_contents,
79 const base::Optional<content::WebContents::CreateParams>& create_params,
79 std::unique_ptr<PageLoadMetricsEmbedderInterface> embedder_interface); 80 std::unique_ptr<PageLoadMetricsEmbedderInterface> embedder_interface);
80 MetricsWebContentsObserver( 81 MetricsWebContentsObserver(
81 content::WebContents* web_contents, 82 content::WebContents* web_contents,
83 const base::Optional<content::WebContents::CreateParams>& create_params,
82 std::unique_ptr<PageLoadMetricsEmbedderInterface> embedder_interface); 84 std::unique_ptr<PageLoadMetricsEmbedderInterface> embedder_interface);
83 ~MetricsWebContentsObserver() override; 85 ~MetricsWebContentsObserver() override;
84 86
85 // content::WebContentsObserver implementation: 87 // content::WebContentsObserver implementation:
86 bool OnMessageReceived(const IPC::Message& message, 88 bool OnMessageReceived(const IPC::Message& message,
87 content::RenderFrameHost* render_frame_host) override; 89 content::RenderFrameHost* render_frame_host) override;
88 void DidFinishNavigation( 90 void DidFinishNavigation(
89 content::NavigationHandle* navigation_handle) override; 91 content::NavigationHandle* navigation_handle) override;
90 void DidRedirectNavigation( 92 void DidRedirectNavigation(
91 content::NavigationHandle* navigation_handle) override; 93 content::NavigationHandle* navigation_handle) override;
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 base::ObserverList<TestingObserver> testing_observers_; 233 base::ObserverList<TestingObserver> testing_observers_;
232 content::WebContentsFrameBindingSet<mojom::PageLoadMetrics> 234 content::WebContentsFrameBindingSet<mojom::PageLoadMetrics>
233 page_load_metrics_binding_; 235 page_load_metrics_binding_;
234 236
235 DISALLOW_COPY_AND_ASSIGN(MetricsWebContentsObserver); 237 DISALLOW_COPY_AND_ASSIGN(MetricsWebContentsObserver);
236 }; 238 };
237 239
238 } // namespace page_load_metrics 240 } // namespace page_load_metrics
239 241
240 #endif // CHROME_BROWSER_PAGE_LOAD_METRICS_METRICS_WEB_CONTENTS_OBSERVER_H_ 242 #endif // CHROME_BROWSER_PAGE_LOAD_METRICS_METRICS_WEB_CONTENTS_OBSERVER_H_
OLDNEW
« no previous file with comments | « chrome/browser/devtools/devtools_window.cc ('k') | chrome/browser/page_load_metrics/metrics_web_contents_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698