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 #include "chrome/browser/autocomplete/history_quick_provider.h" | 5 #include "chrome/browser/autocomplete/history_quick_provider.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/debug/crash_logging.h" | 10 #include "base/debug/crash_logging.h" |
(...skipping 23 matching lines...) Expand all Loading... |
34 #include "components/omnibox/autocomplete_match_type.h" | 34 #include "components/omnibox/autocomplete_match_type.h" |
35 #include "components/omnibox/autocomplete_result.h" | 35 #include "components/omnibox/autocomplete_result.h" |
36 #include "components/omnibox/omnibox_field_trial.h" | 36 #include "components/omnibox/omnibox_field_trial.h" |
37 #include "components/search_engines/template_url.h" | 37 #include "components/search_engines/template_url.h" |
38 #include "components/search_engines/template_url_service.h" | 38 #include "components/search_engines/template_url_service.h" |
39 #include "content/public/browser/notification_source.h" | 39 #include "content/public/browser/notification_source.h" |
40 #include "content/public/browser/notification_types.h" | 40 #include "content/public/browser/notification_types.h" |
41 #include "net/base/escape.h" | 41 #include "net/base/escape.h" |
42 #include "net/base/net_util.h" | 42 #include "net/base/net_util.h" |
43 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" | 43 #include "net/base/registry_controlled_domains/registry_controlled_domain.h" |
44 #include "url/url_parse.h" | 44 #include "url/third_party/mozilla/url_parse.h" |
45 #include "url/url_util.h" | 45 #include "url/url_util.h" |
46 | 46 |
47 bool HistoryQuickProvider::disabled_ = false; | 47 bool HistoryQuickProvider::disabled_ = false; |
48 | 48 |
49 HistoryQuickProvider::HistoryQuickProvider( | 49 HistoryQuickProvider::HistoryQuickProvider( |
50 Profile* profile, | 50 Profile* profile, |
51 InMemoryURLIndex* in_memory_url_index) | 51 InMemoryURLIndex* in_memory_url_index) |
52 : HistoryProvider(profile, AutocompleteProvider::TYPE_HISTORY_QUICK), | 52 : HistoryProvider(profile, AutocompleteProvider::TYPE_HISTORY_QUICK), |
53 languages_(profile_->GetPrefs()->GetString(prefs::kAcceptLanguages)), | 53 languages_(profile_->GetPrefs()->GetString(prefs::kAcceptLanguages)), |
54 in_memory_url_index_(in_memory_url_index) { | 54 in_memory_url_index_(in_memory_url_index) { |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
276 match.description = info.title(); | 276 match.description = info.title(); |
277 match.description_class = SpansFromTermMatch( | 277 match.description_class = SpansFromTermMatch( |
278 history_match.title_matches, match.description.length(), false); | 278 history_match.title_matches, match.description.length(), false); |
279 | 279 |
280 match.RecordAdditionalInfo("typed count", info.typed_count()); | 280 match.RecordAdditionalInfo("typed count", info.typed_count()); |
281 match.RecordAdditionalInfo("visit count", info.visit_count()); | 281 match.RecordAdditionalInfo("visit count", info.visit_count()); |
282 match.RecordAdditionalInfo("last visit", info.last_visit()); | 282 match.RecordAdditionalInfo("last visit", info.last_visit()); |
283 | 283 |
284 return match; | 284 return match; |
285 } | 285 } |
OLD | NEW |