OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #ifndef CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_H_ | 5 #ifndef CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_H_ |
6 #define CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_H_ | 6 #define CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
113 // The raw content of an image thumbnail that will be used as a query for | 113 // The raw content of an image thumbnail that will be used as a query for |
114 // search-by-image frontend. | 114 // search-by-image frontend. |
115 std::string image_thumbnail_content; | 115 std::string image_thumbnail_content; |
116 | 116 |
117 // When searching for an image, the URL of the original image. Callers | 117 // When searching for an image, the URL of the original image. Callers |
118 // should leave this empty for images specified via data: URLs. | 118 // should leave this empty for images specified via data: URLs. |
119 GURL image_url; | 119 GURL image_url; |
120 | 120 |
121 // When searching for an image, the original size of the image. | 121 // When searching for an image, the original size of the image. |
122 gfx::Size image_original_size; | 122 gfx::Size image_original_size; |
123 | |
124 // True for searches issued with the bookmark bar pref set to shown. | |
125 bool bookmark_bar_pinned; | |
Peter Kasting
2013/10/01 01:03:31
Tiny nit: Let's move this up above append_extra_qu
Jered
2013/10/01 18:46:15
Done.
| |
123 }; | 126 }; |
124 | 127 |
125 TemplateURLRef(TemplateURL* owner, Type type); | 128 TemplateURLRef(TemplateURL* owner, Type type); |
126 TemplateURLRef(TemplateURL* owner, size_t index_in_owner); | 129 TemplateURLRef(TemplateURL* owner, size_t index_in_owner); |
127 ~TemplateURLRef(); | 130 ~TemplateURLRef(); |
128 | 131 |
129 // Returns the raw URL. None of the parameters will have been replaced. | 132 // Returns the raw URL. None of the parameters will have been replaced. |
130 std::string GetURL() const; | 133 std::string GetURL() const; |
131 | 134 |
132 // Returns the raw string of the post params. Please see comments in | 135 // Returns the raw string of the post params. Please see comments in |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
231 FRIEND_TEST_ALL_PREFIXES(TemplateURLTest, ParseURLTwoParameters); | 234 FRIEND_TEST_ALL_PREFIXES(TemplateURLTest, ParseURLTwoParameters); |
232 FRIEND_TEST_ALL_PREFIXES(TemplateURLTest, ParseURLNestedParameter); | 235 FRIEND_TEST_ALL_PREFIXES(TemplateURLTest, ParseURLNestedParameter); |
233 FRIEND_TEST_ALL_PREFIXES(TemplateURLTest, URLRefTestImageURLWithPOST); | 236 FRIEND_TEST_ALL_PREFIXES(TemplateURLTest, URLRefTestImageURLWithPOST); |
234 | 237 |
235 // Enumeration of the known types. | 238 // Enumeration of the known types. |
236 enum ReplacementType { | 239 enum ReplacementType { |
237 ENCODING, | 240 ENCODING, |
238 GOOGLE_ASSISTED_QUERY_STATS, | 241 GOOGLE_ASSISTED_QUERY_STATS, |
239 GOOGLE_BASE_URL, | 242 GOOGLE_BASE_URL, |
240 GOOGLE_BASE_SUGGEST_URL, | 243 GOOGLE_BASE_SUGGEST_URL, |
244 GOOGLE_BOOKMARK_BAR_PINNED, | |
241 GOOGLE_CURSOR_POSITION, | 245 GOOGLE_CURSOR_POSITION, |
242 GOOGLE_IMAGE_ORIGINAL_HEIGHT, | 246 GOOGLE_IMAGE_ORIGINAL_HEIGHT, |
243 GOOGLE_IMAGE_ORIGINAL_WIDTH, | 247 GOOGLE_IMAGE_ORIGINAL_WIDTH, |
244 GOOGLE_IMAGE_SEARCH_SOURCE, | 248 GOOGLE_IMAGE_SEARCH_SOURCE, |
245 GOOGLE_IMAGE_THUMBNAIL, | 249 GOOGLE_IMAGE_THUMBNAIL, |
246 GOOGLE_IMAGE_URL, | 250 GOOGLE_IMAGE_URL, |
247 GOOGLE_INSTANT_ENABLED, | 251 GOOGLE_INSTANT_ENABLED, |
248 GOOGLE_INSTANT_EXTENDED_ENABLED, | 252 GOOGLE_INSTANT_EXTENDED_ENABLED, |
249 GOOGLE_NTP_IS_THEMED, | 253 GOOGLE_NTP_IS_THEMED, |
250 GOOGLE_OMNIBOX_START_MARGIN, | 254 GOOGLE_OMNIBOX_START_MARGIN, |
(...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
711 TemplateURLRef instant_url_ref_; | 715 TemplateURLRef instant_url_ref_; |
712 TemplateURLRef image_url_ref_; | 716 TemplateURLRef image_url_ref_; |
713 TemplateURLRef new_tab_url_ref_; | 717 TemplateURLRef new_tab_url_ref_; |
714 | 718 |
715 // TODO(sky): Add date last parsed OSD file. | 719 // TODO(sky): Add date last parsed OSD file. |
716 | 720 |
717 DISALLOW_COPY_AND_ASSIGN(TemplateURL); | 721 DISALLOW_COPY_AND_ASSIGN(TemplateURL); |
718 }; | 722 }; |
719 | 723 |
720 #endif // CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_H_ | 724 #endif // CHROME_BROWSER_SEARCH_ENGINES_TEMPLATE_URL_H_ |
OLD | NEW |