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

Side by Side Diff: components/history/core/browser/history_service.cc

Issue 2723953002: [sync] skeleton implementation of TypedURLSyncBridge (Closed)
Patch Set: rebase Created 3 years, 8 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 unified diff | Download patch
OLDNEW
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 // The history system runs on a background thread so that potentially slow 5 // The history system runs on a background thread so that potentially slow
6 // database operations don't delay the browser. This backend processing is 6 // database operations don't delay the browser. This backend processing is
7 // represented by HistoryBackend. The HistoryService's job is to dispatch to 7 // represented by HistoryBackend. The HistoryService's job is to dispatch to
8 // that thread. 8 // that thread.
9 // 9 //
10 // Main thread History thread 10 // Main thread History thread
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 ScheduleTask(PRIORITY_NORMAL, 227 ScheduleTask(PRIORITY_NORMAL,
228 base::Bind(&HistoryBackend::ClearCachedDataForContextID, 228 base::Bind(&HistoryBackend::ClearCachedDataForContextID,
229 history_backend_, context_id)); 229 history_backend_, context_id));
230 } 230 }
231 231
232 URLDatabase* HistoryService::InMemoryDatabase() { 232 URLDatabase* HistoryService::InMemoryDatabase() {
233 DCHECK(thread_checker_.CalledOnValidThread()); 233 DCHECK(thread_checker_.CalledOnValidThread());
234 return in_memory_backend_ ? in_memory_backend_->db() : nullptr; 234 return in_memory_backend_ ? in_memory_backend_->db() : nullptr;
235 } 235 }
236 236
237 TypedURLSyncBridge* HistoryService::GetTypedURLSyncBridge() const {
238 return history_backend_->GetTypedURLSyncBridge();
239 }
240
237 TypedUrlSyncableService* HistoryService::GetTypedUrlSyncableService() const { 241 TypedUrlSyncableService* HistoryService::GetTypedUrlSyncableService() const {
238 return history_backend_->GetTypedUrlSyncableService(); 242 return history_backend_->GetTypedUrlSyncableService();
239 } 243 }
240 244
241 void HistoryService::Shutdown() { 245 void HistoryService::Shutdown() {
242 DCHECK(thread_checker_.CalledOnValidThread()); 246 DCHECK(thread_checker_.CalledOnValidThread());
243 Cleanup(); 247 Cleanup();
244 } 248 }
245 249
246 void HistoryService::SetKeywordSearchTermsForURL(const GURL& url, 250 void HistoryService::SetKeywordSearchTermsForURL(const GURL& url,
(...skipping 916 matching lines...) Expand 10 before | Expand all | Expand 10 after
1163 return favicon_changed_callback_list_.Add(callback); 1167 return favicon_changed_callback_list_.Add(callback);
1164 } 1168 }
1165 1169
1166 void HistoryService::NotifyFaviconsChanged(const std::set<GURL>& page_urls, 1170 void HistoryService::NotifyFaviconsChanged(const std::set<GURL>& page_urls,
1167 const GURL& icon_url) { 1171 const GURL& icon_url) {
1168 DCHECK(thread_checker_.CalledOnValidThread()); 1172 DCHECK(thread_checker_.CalledOnValidThread());
1169 favicon_changed_callback_list_.Notify(page_urls, icon_url); 1173 favicon_changed_callback_list_.Notify(page_urls, icon_url);
1170 } 1174 }
1171 1175
1172 } // namespace history 1176 } // namespace history
OLDNEW
« no previous file with comments | « components/history/core/browser/history_service.h ('k') | components/history/core/browser/typed_url_sync_bridge.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698