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

Unified Diff: content/renderer/render_frame_impl.cc

Issue 2485783002: PlzNavigate: send searchable form data to the browser side on form submission. (Closed)
Patch Set: rebase&resolve Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/public/common/frame_navigate_params.h ('k') | third_party/WebKit/Source/core/loader/EmptyClients.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_frame_impl.cc
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index 6ddfae756dbae741ae58f2f4d19a68b2ed25cecd..f928a9a9610062bf51196d2921cc0090b5739a1e 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -6105,15 +6105,24 @@ void RenderFrameImpl::BeginNavigation(const NavigationPolicyInfo& info) {
GetRequestContextFrameTypeForWebURLRequest(info.urlRequest) ==
REQUEST_CONTEXT_FRAME_TYPE_NESTED);
+ BeginNavigationParams begin_navigation_params(
+ GetWebURLRequestHeaders(info.urlRequest),
+ GetLoadFlagsForWebURLRequest(info.urlRequest),
+ info.urlRequest.hasUserGesture(),
+ info.urlRequest.skipServiceWorker() !=
+ blink::WebURLRequest::SkipServiceWorker::None,
+ GetRequestContextTypeForWebURLRequest(info.urlRequest));
+
+ if (!info.form.isNull()) {
+ WebSearchableFormData web_searchable_form_data(info.form);
+ begin_navigation_params.searchable_form_url =
+ web_searchable_form_data.url();
+ begin_navigation_params.searchable_form_encoding =
+ web_searchable_form_data.encoding().utf8();
+ }
+
Send(new FrameHostMsg_BeginNavigation(
- routing_id_, MakeCommonNavigationParams(info),
- BeginNavigationParams(
- GetWebURLRequestHeaders(info.urlRequest),
- GetLoadFlagsForWebURLRequest(info.urlRequest),
- info.urlRequest.hasUserGesture(),
- info.urlRequest.skipServiceWorker() !=
- blink::WebURLRequest::SkipServiceWorker::None,
- GetRequestContextTypeForWebURLRequest(info.urlRequest))));
+ routing_id_, MakeCommonNavigationParams(info), begin_navigation_params));
}
void RenderFrameImpl::LoadDataURL(
« no previous file with comments | « content/public/common/frame_navigate_params.h ('k') | third_party/WebKit/Source/core/loader/EmptyClients.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698