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

Unified Diff: components/history/core/browser/history_backend.h

Issue 2723953002: [sync] skeleton implementation of TypedURLSyncBridge (Closed)
Patch Set: rebase Created 3 years, 9 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 | « components/history/core/browser/BUILD.gn ('k') | components/history/core/browser/history_backend.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/history/core/browser/history_backend.h
diff --git a/components/history/core/browser/history_backend.h b/components/history/core/browser/history_backend.h
index 4747695807f5dff18aeea5385056069059a143df..f96d2182c87b8af64de5d9378c85a24f99beffbe 100644
--- a/components/history/core/browser/history_backend.h
+++ b/components/history/core/browser/history_backend.h
@@ -53,6 +53,7 @@ struct HistoryDatabaseParams;
class HistoryDBTask;
class InMemoryHistoryBackend;
class TypedUrlSyncableService;
+class TypedURLSyncBridge;
class HistoryBackendHelper;
class URLDatabase;
@@ -400,6 +401,10 @@ class HistoryBackend : public base::RefCountedThreadSafe<HistoryBackend>,
// is owned by |this| object.
virtual TypedUrlSyncableService* GetTypedUrlSyncableService() const;
+ // Returns the sync bridge for syncing typed urls. The returned service
+ // is owned by |this| object.
+ TypedURLSyncBridge* GetTypedURLSyncBridge() const;
+
// Deleting ------------------------------------------------------------------
virtual void DeleteURLs(const std::vector<GURL>& urls);
@@ -909,10 +914,12 @@ class HistoryBackend : public base::RefCountedThreadSafe<HistoryBackend>,
// List of observers
base::ObserverList<HistoryBackendObserver> observers_;
- // Used to manage syncing of the typed urls datatype. This will be null before
- // Init is called. Defined after observers_ because it unregisters itself as
- // observer during destruction.
+ // Used to manage syncing of the typed urls datatype. They will be null before
+ // Init is called, and only one will be instantiated after Init is called
+ // depending on switches::kSyncUSSTypedURL. Defined after observers_ because
+ // it unregisters itself as observer during destruction.
std::unique_ptr<TypedUrlSyncableService> typed_url_syncable_service_;
+ std::unique_ptr<TypedURLSyncBridge> typed_url_sync_bridge_;
DISALLOW_COPY_AND_ASSIGN(HistoryBackend);
};
« no previous file with comments | « components/history/core/browser/BUILD.gn ('k') | components/history/core/browser/history_backend.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698