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

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

Issue 2406053002: PlzNavigate: Fix the failing ContinueWhereILeftOffTest.PostWithPassword test. (Closed)
Patch Set: Fix test failures Created 4 years, 2 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 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 18 matching lines...) Expand all
29 } 29 }
30 30
31 CommonNavigationParams::CommonNavigationParams() 31 CommonNavigationParams::CommonNavigationParams()
32 : transition(ui::PAGE_TRANSITION_LINK), 32 : transition(ui::PAGE_TRANSITION_LINK),
33 navigation_type(FrameMsg_Navigate_Type::NORMAL), 33 navigation_type(FrameMsg_Navigate_Type::NORMAL),
34 allow_download(true), 34 allow_download(true),
35 should_replace_current_entry(false), 35 should_replace_current_entry(false),
36 report_type(FrameMsg_UILoadMetricsReportType::NO_REPORT), 36 report_type(FrameMsg_UILoadMetricsReportType::NO_REPORT),
37 lofi_state(LOFI_UNSPECIFIED), 37 lofi_state(LOFI_UNSPECIFIED),
38 navigation_start(base::TimeTicks::Now()), 38 navigation_start(base::TimeTicks::Now()),
39 method("GET") {} 39 method("GET"),
40 post_contains_passwords(false) {}
40 41
41 CommonNavigationParams::CommonNavigationParams( 42 CommonNavigationParams::CommonNavigationParams(
42 const GURL& url, 43 const GURL& url,
43 const Referrer& referrer, 44 const Referrer& referrer,
44 ui::PageTransition transition, 45 ui::PageTransition transition,
45 FrameMsg_Navigate_Type::Value navigation_type, 46 FrameMsg_Navigate_Type::Value navigation_type,
46 bool allow_download, 47 bool allow_download,
47 bool should_replace_current_entry, 48 bool should_replace_current_entry,
48 base::TimeTicks ui_timestamp, 49 base::TimeTicks ui_timestamp,
49 FrameMsg_UILoadMetricsReportType::Value report_type, 50 FrameMsg_UILoadMetricsReportType::Value report_type,
50 const GURL& base_url_for_data_url, 51 const GURL& base_url_for_data_url,
51 const GURL& history_url_for_data_url, 52 const GURL& history_url_for_data_url,
52 LoFiState lofi_state, 53 LoFiState lofi_state,
53 const base::TimeTicks& navigation_start, 54 const base::TimeTicks& navigation_start,
54 std::string method, 55 std::string method,
56 bool post_contains_passwords,
55 const scoped_refptr<ResourceRequestBodyImpl>& post_data) 57 const scoped_refptr<ResourceRequestBodyImpl>& post_data)
56 : url(url), 58 : url(url),
57 referrer(referrer), 59 referrer(referrer),
58 transition(transition), 60 transition(transition),
59 navigation_type(navigation_type), 61 navigation_type(navigation_type),
60 allow_download(allow_download), 62 allow_download(allow_download),
61 should_replace_current_entry(should_replace_current_entry), 63 should_replace_current_entry(should_replace_current_entry),
62 ui_timestamp(ui_timestamp), 64 ui_timestamp(ui_timestamp),
63 report_type(report_type), 65 report_type(report_type),
64 base_url_for_data_url(base_url_for_data_url), 66 base_url_for_data_url(base_url_for_data_url),
65 history_url_for_data_url(history_url_for_data_url), 67 history_url_for_data_url(history_url_for_data_url),
66 lofi_state(lofi_state), 68 lofi_state(lofi_state),
67 navigation_start(navigation_start), 69 navigation_start(navigation_start),
68 method(method), 70 method(method),
71 post_contains_passwords(post_contains_passwords),
69 post_data(post_data) { 72 post_data(post_data) {
70 // |method != "POST"| should imply absence of |post_data|. 73 // |method != "POST"| should imply absence of |post_data|.
71 if (method != "POST" && post_data) { 74 if (method != "POST" && post_data) {
72 NOTREACHED(); 75 NOTREACHED();
73 this->post_data = nullptr; 76 this->post_data = nullptr;
74 } 77 }
75 } 78 }
76 79
77 CommonNavigationParams::CommonNavigationParams( 80 CommonNavigationParams::CommonNavigationParams(
78 const CommonNavigationParams& other) = default; 81 const CommonNavigationParams& other) = default;
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 const RequestNavigationParams& request_params) 195 const RequestNavigationParams& request_params)
193 : common_params(common_params), 196 : common_params(common_params),
194 start_params(start_params), 197 start_params(start_params),
195 request_params(request_params) { 198 request_params(request_params) {
196 } 199 }
197 200
198 NavigationParams::~NavigationParams() { 201 NavigationParams::~NavigationParams() {
199 } 202 }
200 203
201 } // namespace content 204 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698