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 #ifndef COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ | 5 #ifndef COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ |
6 #define COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ | 6 #define COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 std::string suggestions_url_post_params; | 49 std::string suggestions_url_post_params; |
50 std::string instant_url_post_params; | 50 std::string instant_url_post_params; |
51 std::string image_url_post_params; | 51 std::string image_url_post_params; |
52 | 52 |
53 // Optional favicon for the TemplateURL. | 53 // Optional favicon for the TemplateURL. |
54 GURL favicon_url; | 54 GURL favicon_url; |
55 | 55 |
56 // URL to the OSD file this came from. May be empty. | 56 // URL to the OSD file this came from. May be empty. |
57 GURL originating_url; | 57 GURL originating_url; |
58 | 58 |
59 // Whether this TemplateURL is shown in the default list of search providers. | |
60 // This is just a property and does not indicate whether the TemplateURL has a | |
61 // TemplateURLRef that supports replacement. Use | |
62 // TemplateURL::ShowInDefaultList() to test both. | |
63 bool show_in_default_list; | |
64 | |
65 // Whether it's safe for auto-modification code (the autogenerator and the | 59 // Whether it's safe for auto-modification code (the autogenerator and the |
66 // code that imports data from other browsers) to replace the TemplateURL. | 60 // code that imports data from other browsers) to replace the TemplateURL. |
67 // This should be set to false for any TemplateURL the user edits, or any | 61 // This should be set to false for any TemplateURL the user edits, or any |
68 // TemplateURL that the user clearly manually edited in the past, like a | 62 // TemplateURL that the user clearly manually edited in the past, like a |
69 // bookmark keyword from another browser. | 63 // bookmark keyword from another browser. |
70 bool safe_for_autoreplace; | 64 bool safe_for_autoreplace; |
71 | 65 |
72 // The list of supported encodings for the search terms. This may be empty, | 66 // The list of supported encodings for the search terms. This may be empty, |
73 // which indicates the terms should be encoded with UTF-8. | 67 // which indicates the terms should be encoded with UTF-8. |
74 std::vector<std::string> input_encodings; | 68 std::vector<std::string> input_encodings; |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
116 | 110 |
117 private: | 111 private: |
118 // Private so we can enforce using the setters and thus enforce that these | 112 // Private so we can enforce using the setters and thus enforce that these |
119 // fields are never empty. | 113 // fields are never empty. |
120 base::string16 short_name_; | 114 base::string16 short_name_; |
121 base::string16 keyword_; | 115 base::string16 keyword_; |
122 std::string url_; | 116 std::string url_; |
123 }; | 117 }; |
124 | 118 |
125 #endif // COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ | 119 #endif // COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ |
OLD | NEW |