Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3131)

Unified Diff: chrome/browser/history/history_backend.cc

Issue 823273003: Switch the history backend from using page ids to navigation entry unique ids. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 12 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/history/history_backend.h ('k') | chrome/browser/history/history_backend_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/history/history_backend.cc
diff --git a/chrome/browser/history/history_backend.cc b/chrome/browser/history/history_backend.cc
index 5e3917805960281aae367eb4c9dc4496dc2d591f..de8ffe0ff09856b015118d8e42ccfd2c0f685bf1 100644
--- a/chrome/browser/history/history_backend.cc
+++ b/chrome/browser/history/history_backend.cc
@@ -380,11 +380,11 @@ SegmentID HistoryBackend::UpdateSegments(
}
void HistoryBackend::UpdateWithPageEndTime(ContextID context_id,
- int32 page_id,
+ int nav_entry_id,
const GURL& url,
Time end_ts) {
// Will be filled with the URL ID and the visit ID of the last addition.
- VisitID visit_id = tracker_.GetLastVisit(context_id, page_id, url);
+ VisitID visit_id = tracker_.GetLastVisit(context_id, nav_entry_id, url);
UpdateVisitDuration(visit_id, end_ts);
}
@@ -408,7 +408,7 @@ void HistoryBackend::AddPage(const HistoryAddPageArgs& request) {
// Will be filled with the URL ID and the visit ID of the last addition.
std::pair<URLID, VisitID> last_ids(0, tracker_.GetLastVisit(
- request.context_id, request.page_id, request.referrer));
+ request.context_id, request.nav_entry_id, request.referrer));
VisitID from_visit_id = last_ids.second;
@@ -571,7 +571,7 @@ void HistoryBackend::AddPage(const HistoryAddPageArgs& request) {
if (stripped_transition != ui::PAGE_TRANSITION_AUTO_SUBFRAME &&
stripped_transition != ui::PAGE_TRANSITION_MANUAL_SUBFRAME &&
!is_keyword_generated) {
- tracker_.AddVisit(request.context_id, request.page_id, request.url,
+ tracker_.AddVisit(request.context_id, request.nav_entry_id, request.url,
last_ids.second);
}
« no previous file with comments | « chrome/browser/history/history_backend.h ('k') | chrome/browser/history/history_backend_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698