OLD | NEW |
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_RENDER_FRAME_HOST_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ |
6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
107 // handler and determine whether a transfer to a different RenderFrameHost is | 107 // handler and determine whether a transfer to a different RenderFrameHost is |
108 // needed. | 108 // needed. |
109 void OnCrossSiteResponse( | 109 void OnCrossSiteResponse( |
110 const GlobalRequestID& global_request_id, | 110 const GlobalRequestID& global_request_id, |
111 scoped_ptr<CrossSiteTransferringRequest> cross_site_transferring_request, | 111 scoped_ptr<CrossSiteTransferringRequest> cross_site_transferring_request, |
112 const std::vector<GURL>& transfer_url_chain, | 112 const std::vector<GURL>& transfer_url_chain, |
113 const Referrer& referrer, | 113 const Referrer& referrer, |
114 PageTransition page_transition, | 114 PageTransition page_transition, |
115 bool should_replace_current_entry); | 115 bool should_replace_current_entry); |
116 | 116 |
| 117 // Called on the current RenderFrameHost when the network response is first |
| 118 // receieved. |
| 119 void OnDeferredAfterResponseStarted(const GlobalRequestID& global_request_id); |
| 120 |
117 // Tells the renderer that this RenderFrame is being swapped out for one in a | 121 // Tells the renderer that this RenderFrame is being swapped out for one in a |
118 // different renderer process. It should run its unload handler, move to | 122 // different renderer process. It should run its unload handler, move to |
119 // a blank document and create a RenderFrameProxy to replace the RenderFrame. | 123 // a blank document and create a RenderFrameProxy to replace the RenderFrame. |
120 // The renderer should preserve the Proxy object until it exits, in case we | 124 // The renderer should preserve the Proxy object until it exits, in case we |
121 // come back. The renderer can exit if it has no other active RenderFrames, | 125 // come back. The renderer can exit if it has no other active RenderFrames, |
122 // but not until WasSwappedOut is called (when it is no longer visible). | 126 // but not until WasSwappedOut is called (when it is no longer visible). |
123 void SwapOut(RenderFrameProxyHost* proxy); | 127 void SwapOut(RenderFrameProxyHost* proxy); |
124 | 128 |
125 void OnSwappedOut(bool timed_out); | 129 void OnSwappedOut(bool timed_out); |
126 bool is_swapped_out() { return is_swapped_out_; } | 130 bool is_swapped_out() { return is_swapped_out_; } |
(...skipping 29 matching lines...) Expand all Loading... |
156 // Notifies the RenderFrame that the JavaScript message that was shown was | 160 // Notifies the RenderFrame that the JavaScript message that was shown was |
157 // closed by the user. | 161 // closed by the user. |
158 void JavaScriptDialogClosed(IPC::Message* reply_msg, | 162 void JavaScriptDialogClosed(IPC::Message* reply_msg, |
159 bool success, | 163 bool success, |
160 const base::string16& user_input, | 164 const base::string16& user_input, |
161 bool dialog_was_suppressed); | 165 bool dialog_was_suppressed); |
162 | 166 |
163 // Called when an HTML5 notification is closed. | 167 // Called when an HTML5 notification is closed. |
164 void NotificationClosed(int notification_id); | 168 void NotificationClosed(int notification_id); |
165 | 169 |
| 170 // Sets whether there is an outstanding transition request. This is called at |
| 171 // the start of a provisional load for the main frame, and cleared when we |
| 172 // hear the response or commit. |
| 173 void SetHasPendingTransitionRequest(bool has_pending_request); |
| 174 |
166 protected: | 175 protected: |
167 friend class RenderFrameHostFactory; | 176 friend class RenderFrameHostFactory; |
168 | 177 |
169 // TODO(nasko): Remove dependency on RenderViewHost here. RenderProcessHost | 178 // TODO(nasko): Remove dependency on RenderViewHost here. RenderProcessHost |
170 // should be the abstraction needed here, but we need RenderViewHost to pass | 179 // should be the abstraction needed here, but we need RenderViewHost to pass |
171 // into WebContentsObserver::FrameDetached for now. | 180 // into WebContentsObserver::FrameDetached for now. |
172 RenderFrameHostImpl(RenderViewHostImpl* render_view_host, | 181 RenderFrameHostImpl(RenderViewHostImpl* render_view_host, |
173 RenderFrameHostDelegate* delegate, | 182 RenderFrameHostDelegate* delegate, |
174 FrameTree* frame_tree, | 183 FrameTree* frame_tree, |
175 FrameTreeNode* frame_tree_node, | 184 FrameTreeNode* frame_tree_node, |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
287 base::TimeTicks send_before_unload_start_time_; | 296 base::TimeTicks send_before_unload_start_time_; |
288 | 297 |
289 base::WeakPtrFactory<RenderFrameHostImpl> weak_ptr_factory_; | 298 base::WeakPtrFactory<RenderFrameHostImpl> weak_ptr_factory_; |
290 | 299 |
291 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostImpl); | 300 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostImpl); |
292 }; | 301 }; |
293 | 302 |
294 } // namespace content | 303 } // namespace content |
295 | 304 |
296 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ | 305 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_IMPL_H_ |
OLD | NEW |