Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #include "components/navigation_interception/navigation_params.h" | 5 #include "components/navigation_interception/navigation_params.h" |
| 6 | 6 |
| 7 namespace navigation_interception { | 7 namespace navigation_interception { |
| 8 | 8 |
| 9 NavigationParams::NavigationParams(const NavigationParams& other) { | 9 NavigationParams::NavigationParams(const NavigationParams& other) { |
| 10 Assign(other); | 10 Assign(other); |
| (...skipping 15 matching lines...) Expand all Loading... | |
| 26 transition_type_(transition_type), | 26 transition_type_(transition_type), |
| 27 is_redirect_(is_redirect), | 27 is_redirect_(is_redirect), |
| 28 is_external_protocol_(is_external_protocol), | 28 is_external_protocol_(is_external_protocol), |
| 29 is_main_frame_(is_main_frame), | 29 is_main_frame_(is_main_frame), |
| 30 base_url_for_data_url_(base_url_for_data_url) {} | 30 base_url_for_data_url_(base_url_for_data_url) {} |
| 31 | 31 |
| 32 void NavigationParams::operator=(const NavigationParams& rhs) { | 32 void NavigationParams::operator=(const NavigationParams& rhs) { |
| 33 Assign(rhs); | 33 Assign(rhs); |
| 34 } | 34 } |
| 35 | 35 |
| 36 void NavigationParams::Assign(const NavigationParams& other) { | 36 void NavigationParams::Assign(const NavigationParams& other) { |
|
jam
2017/03/17 19:16:23
can you just get rid of this method and the manual
sgurun-gerrit only
2017/03/17 19:56:51
that removes a lot of boilerplate.
| |
| 37 url_ = other.url(); | 37 url_ = other.url(); |
| 38 referrer_ = other.referrer(); | 38 referrer_ = other.referrer(); |
| 39 has_user_gesture_ = other.has_user_gesture(); | 39 has_user_gesture_ = other.has_user_gesture(); |
| 40 is_post_ = other.is_post(); | 40 is_post_ = other.is_post(); |
| 41 transition_type_ = other.transition_type(); | 41 transition_type_ = other.transition_type(); |
| 42 is_redirect_ = other.is_redirect(); | 42 is_redirect_ = other.is_redirect(); |
| 43 is_external_protocol_ = other.is_external_protocol(); | 43 is_external_protocol_ = other.is_external_protocol(); |
| 44 is_main_frame_ = other.is_main_frame(); | 44 is_main_frame_ = other.is_main_frame(); |
| 45 base_url_for_data_url_ = other.base_url_for_data_url(); | |
| 45 } | 46 } |
| 46 | 47 |
| 47 } // namespace navigation_interception | 48 } // namespace navigation_interception |
| 48 | 49 |
| OLD | NEW |