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

Unified Diff: components/sync/driver/glue/sync_backend_host.h

Issue 2481313002: [Sync] Move sync thread ownership to ProfileSyncService. (Closed)
Patch Set: Address comments. Created 4 years, 1 month 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
Index: components/sync/driver/glue/sync_backend_host.h
diff --git a/components/sync/driver/glue/sync_backend_host.h b/components/sync/driver/glue/sync_backend_host.h
index 3506830d8c9b5f821ab36db608605a9dc8dff69d..cc6279d0fc73183c3eeab0c4d5b41340a3928d47 100644
--- a/components/sync/driver/glue/sync_backend_host.h
+++ b/components/sync/driver/glue/sync_backend_host.h
@@ -59,7 +59,7 @@ class SyncBackendHost : public BackendDataTypeConfigurer {
// backend instance. May be null.
virtual void Initialize(
SyncFrontend* frontend,
- std::unique_ptr<base::Thread> sync_thread,
+ base::Thread* sync_thread,
const scoped_refptr<base::SingleThreadTaskRunner>& db_thread,
const scoped_refptr<base::SingleThreadTaskRunner>& file_thread,
const WeakHandle<JsEventHandler>& event_handler,
@@ -119,9 +119,7 @@ class SyncBackendHost : public BackendDataTypeConfigurer {
// Called on |frontend_loop_| to kick off shutdown.
// See the implementation and Core::DoShutdown for details.
// Must be called *after* StopSyncingForShutdown.
- // Transfers ownership of the sync thread to the caller which may reuse it
- // with a different SyncBackendHost or join it immediately.
- virtual std::unique_ptr<base::Thread> Shutdown(ShutdownReason reason) = 0;
+ virtual void Shutdown(ShutdownReason reason) = 0;
// Removes all current registrations from the backend on the
// InvalidationService.
@@ -196,8 +194,6 @@ class SyncBackendHost : public BackendDataTypeConfigurer {
// Disables the sending of directory type debug counters.
virtual void DisableDirectoryTypeDebugInfoForwarding() = 0;
- virtual base::MessageLoop* GetSyncLoopForTesting() = 0;
-
// Triggers sync cycle to update |types|.
virtual void RefreshTypesForTest(ModelTypeSet types) = 0;
« no previous file with comments | « components/browser_sync/profile_sync_service_unittest.cc ('k') | components/sync/driver/glue/sync_backend_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698