Index: chrome/browser/autocomplete/search_provider.cc |
diff --git a/chrome/browser/autocomplete/search_provider.cc b/chrome/browser/autocomplete/search_provider.cc |
index f1d7ea1a6a04f1dac1728b7c80e1dd34a3c12bf1..86b7f59f036e26c709cc2e820847fb8468c23528 100644 |
--- a/chrome/browser/autocomplete/search_provider.cc |
+++ b/chrome/browser/autocomplete/search_provider.cc |
@@ -166,15 +166,15 @@ AutocompleteMatch SearchProvider::CreateSearchSuggestion( |
// looks odd if both the first and last s are highlighted. |
if (input_position != 0) { |
match.contents_class.push_back( |
- ACMatchClassification(0, ACMatchClassification::NONE)); |
+ ACMatchClassification(0, ACMatchClassification::MATCH)); |
} |
match.contents_class.push_back( |
- ACMatchClassification(input_position, ACMatchClassification::DIM)); |
+ ACMatchClassification(input_position, ACMatchClassification::NONE)); |
size_t next_fragment_position = input_position + input_text.length(); |
if (next_fragment_position < query_string.length()) { |
match.contents_class.push_back( |
ACMatchClassification(next_fragment_position, |
- ACMatchClassification::NONE)); |
+ ACMatchClassification::MATCH)); |
} |
} |
} else { |
@@ -636,7 +636,7 @@ void SearchProvider::DoHistoryQuery(bool minimal_changes) { |
// now, this seems OK compared with the complexity of a real fix, which would |
// require multiple searches and tracking of "single- vs. multi-word" in the |
// database. |
- int num_matches = kMaxMatches * 5; |
+ int num_matches = kMaxSuggestMatches * 4; |
brettw
2013/06/04 23:43:12
This change needs to be reverted.
Peter Kasting
2013/06/06 18:52:16
I assume you wrote this because you've reverted th
|
const TemplateURL* default_url = providers_.GetDefaultProviderURL(); |
if (default_url) { |
url_db->GetMostRecentKeywordSearchTerms(default_url->id(), input_.text(), |
@@ -1106,7 +1106,7 @@ void SearchProvider::ConvertResultsToAutocompleteMatches() { |
AddNavigationResultsToMatches(default_results_.navigation_results, false); |
// Allow additional match(es) for verbatim results if present. |
- const size_t max_total_matches = kMaxMatches + verbatim_matches_size; |
+ const size_t max_total_matches = kMaxSuggestMatches + verbatim_matches_size; |
brettw
2013/06/04 23:43:12
Ditto
|
std::partial_sort(matches_.begin(), |
matches_.begin() + std::min(max_total_matches, matches_.size()), |
matches_.end(), &AutocompleteMatch::MoreRelevant); |