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

Side by Side Diff: content/common/navigation_params.cc

Issue 2099243002: PlzNavigate: properly set the initiator of the navigation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "content/common/navigation_params.h" 5 #include "content/common/navigation_params.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 #include "content/common/service_worker/service_worker_types.h" 9 #include "content/common/service_worker/service_worker_types.h"
10 #include "content/public/common/browser_side_navigation_policy.h" 10 #include "content/public/common/browser_side_navigation_policy.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 : load_flags(0), 83 : load_flags(0),
84 has_user_gesture(false), 84 has_user_gesture(false),
85 skip_service_worker(false), 85 skip_service_worker(false),
86 request_context_type(REQUEST_CONTEXT_TYPE_LOCATION) {} 86 request_context_type(REQUEST_CONTEXT_TYPE_LOCATION) {}
87 87
88 BeginNavigationParams::BeginNavigationParams( 88 BeginNavigationParams::BeginNavigationParams(
89 std::string headers, 89 std::string headers,
90 int load_flags, 90 int load_flags,
91 bool has_user_gesture, 91 bool has_user_gesture,
92 bool skip_service_worker, 92 bool skip_service_worker,
93 RequestContextType request_context_type) 93 RequestContextType request_context_type,
94 const base::Optional<url::Origin>& initiator)
94 : headers(headers), 95 : headers(headers),
95 load_flags(load_flags), 96 load_flags(load_flags),
96 has_user_gesture(has_user_gesture), 97 has_user_gesture(has_user_gesture),
97 skip_service_worker(skip_service_worker), 98 skip_service_worker(skip_service_worker),
98 request_context_type(request_context_type) {} 99 request_context_type(request_context_type),
100 initiator(initiator) {}
99 101
100 BeginNavigationParams::BeginNavigationParams( 102 BeginNavigationParams::BeginNavigationParams(
101 const BeginNavigationParams& other) = default; 103 const BeginNavigationParams& other) = default;
102 104
105 BeginNavigationParams::~BeginNavigationParams() {}
106
103 StartNavigationParams::StartNavigationParams() 107 StartNavigationParams::StartNavigationParams()
104 : transferred_request_child_id(-1), 108 : transferred_request_child_id(-1),
105 transferred_request_request_id(-1) { 109 transferred_request_request_id(-1) {
106 } 110 }
107 111
108 StartNavigationParams::StartNavigationParams( 112 StartNavigationParams::StartNavigationParams(
109 const std::string& extra_headers, 113 const std::string& extra_headers,
110 int transferred_request_child_id, 114 int transferred_request_child_id,
111 int transferred_request_request_id) 115 int transferred_request_request_id)
112 : extra_headers(extra_headers), 116 : extra_headers(extra_headers),
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 const RequestNavigationParams& request_params) 189 const RequestNavigationParams& request_params)
186 : common_params(common_params), 190 : common_params(common_params),
187 start_params(start_params), 191 start_params(start_params),
188 request_params(request_params) { 192 request_params(request_params) {
189 } 193 }
190 194
191 NavigationParams::~NavigationParams() { 195 NavigationParams::~NavigationParams() {
192 } 196 }
193 197
194 } // namespace content 198 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698