| OLD | NEW |
| 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/memory/ref_counted_memory.h" | 7 #include "base/memory/ref_counted_memory.h" |
| 8 | 8 |
| 9 namespace content { | 9 namespace content { |
| 10 CommonNavigationParams::CommonNavigationParams() | 10 CommonNavigationParams::CommonNavigationParams() |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 transition(transition), | 27 transition(transition), |
| 28 navigation_type(navigation_type), | 28 navigation_type(navigation_type), |
| 29 allow_download(allow_download), | 29 allow_download(allow_download), |
| 30 ui_timestamp(ui_timestamp), | 30 ui_timestamp(ui_timestamp), |
| 31 report_type(report_type) { | 31 report_type(report_type) { |
| 32 } | 32 } |
| 33 | 33 |
| 34 CommonNavigationParams::~CommonNavigationParams() { | 34 CommonNavigationParams::~CommonNavigationParams() { |
| 35 } | 35 } |
| 36 | 36 |
| 37 RequestNavigationParams::RequestNavigationParams() : is_post(false) {} | 37 BeginNavigationParams::BeginNavigationParams() |
| 38 | 38 : load_flags(0), |
| 39 RequestNavigationParams::RequestNavigationParams( | 39 has_user_gesture(false) { |
| 40 bool is_post, | |
| 41 const std::string& extra_headers, | |
| 42 const base::RefCountedMemory* post_data) | |
| 43 : is_post(is_post), | |
| 44 extra_headers(extra_headers) { | |
| 45 if (post_data) { | |
| 46 browser_initiated_post_data.assign( | |
| 47 post_data->front(), post_data->front() + post_data->size()); | |
| 48 } | |
| 49 } | 40 } |
| 50 | 41 |
| 51 RequestNavigationParams::~RequestNavigationParams() {} | 42 BeginNavigationParams::BeginNavigationParams(std::string method, |
| 43 std::string headers, |
| 44 int load_flags, |
| 45 bool has_user_gesture) |
| 46 : method(method), |
| 47 headers(headers), |
| 48 load_flags(load_flags), |
| 49 has_user_gesture(has_user_gesture) { |
| 50 } |
| 52 | 51 |
| 53 CommitNavigationParams::CommitNavigationParams() | 52 CommitNavigationParams::CommitNavigationParams() |
| 54 : is_overriding_user_agent(false) { | 53 : is_overriding_user_agent(false) { |
| 55 } | 54 } |
| 56 | 55 |
| 57 CommitNavigationParams::CommitNavigationParams(const PageState& page_state, | 56 CommitNavigationParams::CommitNavigationParams(const PageState& page_state, |
| 58 bool is_overriding_user_agent, | 57 bool is_overriding_user_agent, |
| 59 base::TimeTicks navigation_start) | 58 base::TimeTicks navigation_start) |
| 60 : page_state(page_state), | 59 : page_state(page_state), |
| 61 is_overriding_user_agent(is_overriding_user_agent), | 60 is_overriding_user_agent(is_overriding_user_agent), |
| 62 browser_navigation_start(navigation_start) { | 61 browser_navigation_start(navigation_start) { |
| 63 } | 62 } |
| 64 | 63 |
| 65 CommitNavigationParams::~CommitNavigationParams() {} | 64 CommitNavigationParams::~CommitNavigationParams() {} |
| 66 | 65 |
| 67 } // namespace content | 66 } // namespace content |
| OLD | NEW |