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

Unified Diff: components/sync_driver/glue/sync_backend_registrar.h

Issue 1907683003: Convert //components/sync_driver from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Build fix, address feedback Created 4 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 side-by-side diff with in-line comments
Download patch
Index: components/sync_driver/glue/sync_backend_registrar.h
diff --git a/components/sync_driver/glue/sync_backend_registrar.h b/components/sync_driver/glue/sync_backend_registrar.h
index d59b059827c8c618ec85a6cf5b28acd3dac8c07c..319fddca2656017a43374ae7c1e605af43d915ba 100644
--- a/components/sync_driver/glue/sync_backend_registrar.h
+++ b/components/sync_driver/glue/sync_backend_registrar.h
@@ -8,13 +8,13 @@
#include <stdint.h>
#include <map>
+#include <memory>
#include <string>
#include <vector>
#include "base/compiler_specific.h"
#include "base/macros.h"
#include "base/memory/ref_counted.h"
-#include "base/memory/scoped_ptr.h"
#include "base/synchronization/lock.h"
#include "base/threading/thread.h"
#include "sync/internal_api/public/base/model_type.h"
@@ -51,7 +51,7 @@ class SyncBackendRegistrar : public syncer::SyncManager::ChangeDelegate,
SyncBackendRegistrar(
const std::string& name,
sync_driver::SyncClient* sync_client,
- scoped_ptr<base::Thread> sync_thread,
+ std::unique_ptr<base::Thread> sync_thread,
const scoped_refptr<base::SingleThreadTaskRunner>& ui_thread,
const scoped_refptr<base::SingleThreadTaskRunner>& db_thread,
const scoped_refptr<base::SingleThreadTaskRunner>& file_thread);
@@ -133,7 +133,7 @@ class SyncBackendRegistrar : public syncer::SyncManager::ChangeDelegate,
void OnWorkerLoopDestroyed(syncer::ModelSafeGroup group) override;
// Release ownership of |sync_thread_|. Called when sync is disabled.
- scoped_ptr<base::Thread> ReleaseSyncThread();
+ std::unique_ptr<base::Thread> ReleaseSyncThread();
// Unregister workers from loop destruction observation.
void Shutdown();
@@ -220,7 +220,7 @@ class SyncBackendRegistrar : public syncer::SyncManager::ChangeDelegate,
// objects above because tasks on sync thread depend on those objects,
// e.g. Shutdown() depends on |lock_|, SyncManager::Init() depends on
// workers, etc.
- scoped_ptr<base::Thread> sync_thread_;
+ std::unique_ptr<base::Thread> sync_thread_;
// Set of types with non-blocking implementation (as opposed to directory
// based).
« no previous file with comments | « components/sync_driver/glue/sync_backend_host_mock.cc ('k') | components/sync_driver/glue/sync_backend_registrar.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698