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

Side by Side Diff: content/browser/frame_host/navigator_impl.h

Issue 367653002: Add a FrameHostMsg_BeginNavigation IPC (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added a stub for CommitNavigation to clarify lifetime of rfh Created 6 years, 5 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
« no previous file with comments | « content/browser/frame_host/navigator.h ('k') | content/browser/frame_host/navigator_impl.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_
6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "content/browser/frame_host/navigation_controller_impl.h" 9 #include "content/browser/frame_host/navigation_controller_impl.h"
10 #include "content/browser/frame_host/navigator.h" 10 #include "content/browser/frame_host/navigator.h"
11 #include "content/common/content_export.h" 11 #include "content/common/content_export.h"
12 12
13 struct FrameMsg_Navigate_Params;
14
13 namespace content { 15 namespace content {
14 16
15 class NavigationControllerImpl; 17 class NavigationControllerImpl;
16 class NavigatorDelegate; 18 class NavigatorDelegate;
17 struct LoadCommittedDetails; 19 struct LoadCommittedDetails;
18 20
19 // This class is an implementation of Navigator, responsible for managing 21 // This class is an implementation of Navigator, responsible for managing
20 // navigations in regular browser tabs. 22 // navigations in regular browser tabs.
21 class CONTENT_EXPORT NavigatorImpl : public Navigator { 23 class CONTENT_EXPORT NavigatorImpl : public Navigator {
22 public: 24 public:
23 NavigatorImpl(NavigationControllerImpl* navigation_controller, 25 NavigatorImpl(NavigationControllerImpl* navigation_controller,
24 NavigatorDelegate* delegate); 26 NavigatorDelegate* delegate);
25 27
28 // Fills in |params| based on the content of |entry|.
29 static void MakeNavigateParams(const NavigationEntryImpl& entry,
30 const NavigationControllerImpl& controller,
31 NavigationController::ReloadType reload_type,
32 base::TimeTicks navigation_start,
33 FrameMsg_Navigate_Params* params);
34
26 // Navigator implementation. 35 // Navigator implementation.
27 virtual NavigationController* GetController() OVERRIDE; 36 virtual NavigationController* GetController() OVERRIDE;
28 virtual void DidStartProvisionalLoad(RenderFrameHostImpl* render_frame_host, 37 virtual void DidStartProvisionalLoad(RenderFrameHostImpl* render_frame_host,
29 const GURL& url) OVERRIDE; 38 const GURL& url) OVERRIDE;
30 virtual void DidFailProvisionalLoadWithError( 39 virtual void DidFailProvisionalLoadWithError(
31 RenderFrameHostImpl* render_frame_host, 40 RenderFrameHostImpl* render_frame_host,
32 const FrameHostMsg_DidFailProvisionalLoadWithError_Params& params) 41 const FrameHostMsg_DidFailProvisionalLoadWithError_Params& params)
33 OVERRIDE; 42 OVERRIDE;
34 virtual void DidFailLoadWithError( 43 virtual void DidFailLoadWithError(
35 RenderFrameHostImpl* render_frame_host, 44 RenderFrameHostImpl* render_frame_host,
(...skipping 23 matching lines...) Expand all
59 RenderFrameHostImpl* render_frame_host, 68 RenderFrameHostImpl* render_frame_host,
60 const GURL& url, 69 const GURL& url,
61 const std::vector<GURL>& redirect_chain, 70 const std::vector<GURL>& redirect_chain,
62 const Referrer& referrer, 71 const Referrer& referrer,
63 PageTransition page_transition, 72 PageTransition page_transition,
64 WindowOpenDisposition disposition, 73 WindowOpenDisposition disposition,
65 const GlobalRequestID& transferred_global_request_id, 74 const GlobalRequestID& transferred_global_request_id,
66 bool should_replace_current_entry, 75 bool should_replace_current_entry,
67 bool user_gesture) OVERRIDE; 76 bool user_gesture) OVERRIDE;
68 77
78 // Will crash the browser if |render_frame_host| is a Web-UI renderer that
79 // tries to display a non Web UI |url|.
80 virtual void CheckWebUIRendererDoesNotDisplayNormalURL(
81 RenderFrameHostImpl* render_frame_host,
82 const GURL& url) OVERRIDE;
83
69 private: 84 private:
70 virtual ~NavigatorImpl() {} 85 virtual ~NavigatorImpl() {}
71 86
72 // Navigates to the given entry, which must be the pending entry. Private 87 // Navigates to the given entry, which must be the pending entry. Private
73 // because all callers should use NavigateToPendingEntry. 88 // because all callers should use NavigateToPendingEntry.
74 bool NavigateToEntry( 89 bool NavigateToEntry(
75 RenderFrameHostImpl* render_frame_host, 90 RenderFrameHostImpl* render_frame_host,
76 const NavigationEntryImpl& entry, 91 const NavigationEntryImpl& entry,
77 NavigationController::ReloadType reload_type); 92 NavigationController::ReloadType reload_type);
78 93
(...skipping 11 matching lines...) Expand all
90 105
91 // System time at which the current load was started. 106 // System time at which the current load was started.
92 base::TimeTicks current_load_start_; 107 base::TimeTicks current_load_start_;
93 108
94 DISALLOW_COPY_AND_ASSIGN(NavigatorImpl); 109 DISALLOW_COPY_AND_ASSIGN(NavigatorImpl);
95 }; 110 };
96 111
97 } // namespace content 112 } // namespace content
98 113
99 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_ 114 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/frame_host/navigator.h ('k') | content/browser/frame_host/navigator_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698