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_AUTOCOMPLETE_AUTOCOMPLETE_MATCH_H_ | 5 #ifndef CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_MATCH_H_ |
6 #define CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_MATCH_H_ | 6 #define CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_MATCH_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 HISTORY_KEYWORD, // A past page whose keyword contains the input. | 82 HISTORY_KEYWORD, // A past page whose keyword contains the input. |
83 NAVSUGGEST, // A suggested URL. | 83 NAVSUGGEST, // A suggested URL. |
84 SEARCH_WHAT_YOU_TYPED, // The input as a search query (with the default | 84 SEARCH_WHAT_YOU_TYPED, // The input as a search query (with the default |
85 // engine). | 85 // engine). |
86 SEARCH_HISTORY, // A past search (with the default engine) | 86 SEARCH_HISTORY, // A past search (with the default engine) |
87 // containing the input. | 87 // containing the input. |
88 SEARCH_SUGGEST, // A suggested search (with the default engine). | 88 SEARCH_SUGGEST, // A suggested search (with the default engine). |
89 SEARCH_OTHER_ENGINE, // A search with a non-default engine. | 89 SEARCH_OTHER_ENGINE, // A search with a non-default engine. |
90 EXTENSION_APP, // An Extension App with a title/url that contains | 90 EXTENSION_APP, // An Extension App with a title/url that contains |
91 // the input. | 91 // the input. |
| 92 CONTACT, // One of the user's contacts. |
92 NUM_TYPES, | 93 NUM_TYPES, |
93 }; | 94 }; |
94 | 95 |
95 // Null-terminated array of characters that are not valid within |contents| | 96 // Null-terminated array of characters that are not valid within |contents| |
96 // and |description| strings. | 97 // and |description| strings. |
97 static const char16 kInvalidChars[]; | 98 static const char16 kInvalidChars[]; |
98 | 99 |
99 AutocompleteMatch(); | 100 AutocompleteMatch(); |
100 AutocompleteMatch(AutocompleteProvider* provider, | 101 AutocompleteMatch(AutocompleteProvider* provider, |
101 int relevance, | 102 int relevance, |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
312 const string16& text, | 313 const string16& text, |
313 const ACMatchClassifications& classifications) const; | 314 const ACMatchClassifications& classifications) const; |
314 #endif | 315 #endif |
315 }; | 316 }; |
316 | 317 |
317 typedef AutocompleteMatch::ACMatchClassification ACMatchClassification; | 318 typedef AutocompleteMatch::ACMatchClassification ACMatchClassification; |
318 typedef std::vector<ACMatchClassification> ACMatchClassifications; | 319 typedef std::vector<ACMatchClassification> ACMatchClassifications; |
319 typedef std::vector<AutocompleteMatch> ACMatches; | 320 typedef std::vector<AutocompleteMatch> ACMatches; |
320 | 321 |
321 #endif // CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_MATCH_H_ | 322 #endif // CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_MATCH_H_ |
OLD | NEW |