Index: chrome/browser/history/url_index_private_data.cc |
diff --git a/chrome/browser/history/url_index_private_data.cc b/chrome/browser/history/url_index_private_data.cc |
index 5b9b71076689298cd38d2064574c69d160d85425..a65ee1f8199cfced3710f04d3f40ef41ce413f14 100644 |
--- a/chrome/browser/history/url_index_private_data.cc |
+++ b/chrome/browser/history/url_index_private_data.cc |
@@ -25,8 +25,8 @@ |
#include "chrome/browser/history/history_db_task.h" |
#include "chrome/browser/history/history_service.h" |
#include "chrome/browser/history/in_memory_url_index.h" |
-#include "components/bookmarks/core/browser/bookmark_service.h" |
#include "components/bookmarks/core/browser/bookmark_utils.h" |
+#include "components/history/core/browser/history_client.h" |
#include "net/base/net_util.h" |
#if defined(USE_SYSTEM_PROTOBUF) |
@@ -119,7 +119,7 @@ bool UpdateRecentVisitsFromHistoryDBTask::RunOnDBThread( |
HistoryBackend* backend, |
HistoryDatabase* db) { |
// Make sure the private data is going to get as many recent visits as |
- // ScoredHistoryMatch::GetFrecency() hopes to use. |
+ // ScoredHistoryMatch::GetFrequency() hopes to use. |
DCHECK_GE(kMaxVisitsToStoreInCache, ScoredHistoryMatch::kMaxVisitsToScore); |
succeeded_ = db->GetMostRecentVisitsForURL(url_id_, |
kMaxVisitsToStoreInCache, |
@@ -152,7 +152,7 @@ ScoredHistoryMatches URLIndexPrivateData::HistoryItemsForTerms( |
base::string16 search_string, |
size_t cursor_position, |
const std::string& languages, |
- BookmarkService* bookmark_service) { |
+ HistoryClient* history_client) { |
// If cursor position is set and useful (not at either end of the |
// string), allow the search string to be broken at cursor position. |
// We do this by pretending there's a space where the cursor is. |
@@ -244,7 +244,7 @@ ScoredHistoryMatches URLIndexPrivateData::HistoryItemsForTerms( |
return scored_items; |
} |
scored_items = std::for_each(history_id_set.begin(), history_id_set.end(), |
- AddHistoryMatch(*this, languages, bookmark_service, lower_raw_string, |
+ AddHistoryMatch(*this, languages, history_client, lower_raw_string, |
lower_raw_terms, base::Time::Now())).ScoredMatches(); |
// Select and sort only the top kMaxMatches results. |
@@ -490,7 +490,7 @@ scoped_refptr<URLIndexPrivateData> URLIndexPrivateData::Duplicate() const { |
// pre_filter_item_count_ |
// post_filter_item_count_ |
// post_scoring_item_count_ |
-}; |
+} |
bool URLIndexPrivateData::Empty() const { |
return history_info_map_.empty(); |
@@ -724,7 +724,7 @@ bool URLIndexPrivateData::IndexRow( |
// So we don't do any thread checks. |
VisitVector recent_visits; |
// Make sure the private data is going to get as many recent visits as |
- // ScoredHistoryMatch::GetFrecency() hopes to use. |
+ // ScoredHistoryMatch::GetFrequency() hopes to use. |
DCHECK_GE(kMaxVisitsToStoreInCache, ScoredHistoryMatch::kMaxVisitsToScore); |
if (history_db->GetMostRecentVisitsForURL(row_id, |
kMaxVisitsToStoreInCache, |
@@ -1264,13 +1264,13 @@ URLIndexPrivateData::SearchTermCacheItem::~SearchTermCacheItem() {} |
URLIndexPrivateData::AddHistoryMatch::AddHistoryMatch( |
const URLIndexPrivateData& private_data, |
const std::string& languages, |
- BookmarkService* bookmark_service, |
+ HistoryClient* history_client, |
const base::string16& lower_string, |
const String16Vector& lower_terms, |
const base::Time now) |
: private_data_(private_data), |
languages_(languages), |
- bookmark_service_(bookmark_service), |
+ history_client_(history_client), |
lower_string_(lower_string), |
lower_terms_(lower_terms), |
now_(now) { |
@@ -1306,7 +1306,7 @@ void URLIndexPrivateData::AddHistoryMatch::operator()( |
DCHECK(starts_pos != private_data_.word_starts_map_.end()); |
ScoredHistoryMatch match(hist_item, visits, languages_, lower_string_, |
lower_terms_, lower_terms_to_word_starts_offsets_, |
- starts_pos->second, now_, bookmark_service_); |
+ starts_pos->second, now_, history_client_); |
if (match.raw_score() > 0) |
scored_matches_.push_back(match); |
} |