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

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

Issue 1693563002: PROTOTYPE: PlzNavigate: use a Mojo data pipe to stream navigation data to the renderer. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Browser sends URLRequest id to the renderer and renderer uses intermediary buffer for data: none he… Created 4 years, 8 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 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_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_
6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/time/time.h" 9 #include "base/time/time.h"
10 #include "content/browser/frame_host/navigator_delegate.h" 10 #include "content/browser/frame_host/navigator_delegate.h"
11 #include "content/common/content_export.h" 11 #include "content/common/content_export.h"
12 #include "content/public/browser/navigation_controller.h" 12 #include "content/public/browser/navigation_controller.h"
13 #include "mojo/public/cpp/system/data_pipe.h"
13 #include "ui/base/window_open_disposition.h" 14 #include "ui/base/window_open_disposition.h"
14 15
15 class GURL; 16 class GURL;
16 struct FrameHostMsg_BeginNavigation_Params; 17 struct FrameHostMsg_BeginNavigation_Params;
17 struct FrameHostMsg_DidCommitProvisionalLoad_Params; 18 struct FrameHostMsg_DidCommitProvisionalLoad_Params;
18 struct FrameHostMsg_DidFailProvisionalLoadWithError_Params; 19 struct FrameHostMsg_DidFailProvisionalLoadWithError_Params;
19 20
20 namespace base { 21 namespace base {
21 class TimeTicks; 22 class TimeTicks;
22 } 23 }
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 const CommonNavigationParams& common_params, 148 const CommonNavigationParams& common_params,
148 const BeginNavigationParams& begin_params, 149 const BeginNavigationParams& begin_params,
149 scoped_refptr<ResourceRequestBody> body); 150 scoped_refptr<ResourceRequestBody> body);
150 151
151 // PlzNavigate 152 // PlzNavigate
152 // Signal |render_frame_host| that a navigation is ready to commit (the 153 // Signal |render_frame_host| that a navigation is ready to commit (the
153 // response to the navigation request has been received). 154 // response to the navigation request has been received).
154 virtual void CommitNavigation(NavigationRequest* navigation_request, 155 virtual void CommitNavigation(NavigationRequest* navigation_request,
155 ResourceResponse* response, 156 ResourceResponse* response,
156 scoped_ptr<StreamHandle> body); 157 scoped_ptr<StreamHandle> body);
158 // TODO(carlosk): there can only be one... At some point in time.
159 virtual void CommitNavigation(
160 NavigationRequest* navigation_request,
161 ResourceResponse* response,
162 mojo::ScopedDataPipeConsumerHandle data_consumer_handle,
163 int request_id);
157 164
158 // PlzNavigate 165 // PlzNavigate
159 // Called when a NavigationRequest for |frame_tree_node| failed. An 166 // Called when a NavigationRequest for |frame_tree_node| failed. An
160 // appropriate RenderFrameHost should be selected and asked to show an error 167 // appropriate RenderFrameHost should be selected and asked to show an error
161 // page. |has_stale_copy_in_cache| is true if there is a stale copy of the 168 // page. |has_stale_copy_in_cache| is true if there is a stale copy of the
162 // unreachable page in cache. 169 // unreachable page in cache.
163 virtual void FailedNavigation(FrameTreeNode* frame_tree_node, 170 virtual void FailedNavigation(FrameTreeNode* frame_tree_node,
164 bool has_stale_copy_in_cache, 171 bool has_stale_copy_in_cache,
165 int error_code) {} 172 int error_code) {}
166 173
(...skipping 18 matching lines...) Expand all
185 const base::TimeTicks& renderer_before_unload_end_time) {} 192 const base::TimeTicks& renderer_before_unload_end_time) {}
186 193
187 protected: 194 protected:
188 friend class base::RefCounted<Navigator>; 195 friend class base::RefCounted<Navigator>;
189 virtual ~Navigator() {} 196 virtual ~Navigator() {}
190 }; 197 };
191 198
192 } // namespace content 199 } // namespace content
193 200
194 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_ 201 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATOR_H_
OLDNEW
« no previous file with comments | « content/browser/frame_host/navigation_request.cc ('k') | content/browser/frame_host/navigator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698