Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 "chrome/common/instant_types.h" | 5 #include "chrome/common/instant_types.h" |
| 6 | 6 |
| 7 #include "base/strings/utf_string_conversions.h" | 7 #include "base/strings/utf_string_conversions.h" |
| 8 #include "net/base/escape.h" | 8 #include "net/base/escape.h" |
| 9 | 9 |
| 10 namespace { | 10 namespace { |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 81 has_attribution == rhs.has_attribution && | 81 has_attribution == rhs.has_attribution && |
| 82 logo_alternate == rhs.logo_alternate; | 82 logo_alternate == rhs.logo_alternate; |
| 83 } | 83 } |
| 84 | 84 |
| 85 const char kSearchQueryKey[] = "q"; | 85 const char kSearchQueryKey[] = "q"; |
| 86 const char kOriginalQueryKey[] = "oq"; | 86 const char kOriginalQueryKey[] = "oq"; |
| 87 const char kRLZParameterKey[] = "rlz"; | 87 const char kRLZParameterKey[] = "rlz"; |
| 88 const char kInputEncodingKey[] = "ie"; | 88 const char kInputEncodingKey[] = "ie"; |
| 89 const char kAssistedQueryStatsKey[] = "aqs"; | 89 const char kAssistedQueryStatsKey[] = "aqs"; |
| 90 | 90 |
| 91 InstantMostVisitedItem::InstantMostVisitedItem() {} | |
| 92 | |
| 93 InstantMostVisitedItem::~InstantMostVisitedItem() {} | |
|
kmadhusu
2015/07/30 21:57:02
Any specific reason to define an empty constructor
fserb
2015/07/31 17:08:17
The build complains that the struct has more than
| |
| 94 | |
| 91 EmbeddedSearchRequestParams::EmbeddedSearchRequestParams() { | 95 EmbeddedSearchRequestParams::EmbeddedSearchRequestParams() { |
| 92 } | 96 } |
| 93 | 97 |
| 94 EmbeddedSearchRequestParams::EmbeddedSearchRequestParams(const GURL& url) { | 98 EmbeddedSearchRequestParams::EmbeddedSearchRequestParams(const GURL& url) { |
| 95 const std::string& url_params(url.ref().empty()? url.query() : url.ref()); | 99 const std::string& url_params(url.ref().empty()? url.query() : url.ref()); |
| 96 url::Component query, key, value; | 100 url::Component query, key, value; |
| 97 query.len = static_cast<int>(url_params.size()); | 101 query.len = static_cast<int>(url_params.size()); |
| 98 | 102 |
| 99 const net::UnescapeRule::Type unescape_rules = | 103 const net::UnescapeRule::Type unescape_rules = |
| 100 net::UnescapeRule::SPOOFING_AND_CONTROL_CHARS | | 104 net::UnescapeRule::SPOOFING_AND_CONTROL_CHARS | |
| (...skipping 20 matching lines...) Expand all Loading... | |
| 121 value_param, net::UnescapeRule::NORMAL); | 125 value_param, net::UnescapeRule::NORMAL); |
| 122 } else if (key_param == kAssistedQueryStatsKey) { | 126 } else if (key_param == kAssistedQueryStatsKey) { |
| 123 assisted_query_stats = net::UnescapeAndDecodeUTF8URLComponent( | 127 assisted_query_stats = net::UnescapeAndDecodeUTF8URLComponent( |
| 124 value_param, net::UnescapeRule::NORMAL); | 128 value_param, net::UnescapeRule::NORMAL); |
| 125 } | 129 } |
| 126 } | 130 } |
| 127 } | 131 } |
| 128 | 132 |
| 129 EmbeddedSearchRequestParams::~EmbeddedSearchRequestParams() { | 133 EmbeddedSearchRequestParams::~EmbeddedSearchRequestParams() { |
| 130 } | 134 } |
| OLD | NEW |