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

Unified Diff: components/sync_driver/non_blocking_data_type_manager.h

Issue 1096983002: Update usages of std::map to use ScopedPtrMap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@passwordmanager-scopedmemory
Patch Set: Rebase. Created 5 years, 6 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/policy/core/common/schema.cc ('k') | components/sync_driver/non_blocking_data_type_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/sync_driver/non_blocking_data_type_manager.h
diff --git a/components/sync_driver/non_blocking_data_type_manager.h b/components/sync_driver/non_blocking_data_type_manager.h
index 762ccab2e5d17c3a54f51f2c4b954b08d539374d..de9c3de29b3b2a0ea9d3116164213e4ad5f0b7dc 100644
--- a/components/sync_driver/non_blocking_data_type_manager.h
+++ b/components/sync_driver/non_blocking_data_type_manager.h
@@ -5,12 +5,10 @@
#ifndef COMPONENTS_SYNC_DRIVER_NON_BLOCKING_DATA_TYPE_MANAGER_H_
#define COMPONENTS_SYNC_DRIVER_NON_BLOCKING_DATA_TYPE_MANAGER_H_
-#include <map>
-
+#include "base/containers/scoped_ptr_map.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
-#include "base/stl_util.h"
#include "sync/internal_api/public/base/model_type.h"
namespace base {
@@ -66,16 +64,12 @@ class NonBlockingDataTypeManager {
syncer::ModelTypeSet GetRegisteredTypes() const;
private:
- typedef
- std::map<syncer::ModelType, NonBlockingDataTypeController*>
+ typedef base::ScopedPtrMap<syncer::ModelType,
+ scoped_ptr<NonBlockingDataTypeController>>
NonBlockingDataTypeControllerMap;
// List of data type controllers for non-blocking types.
NonBlockingDataTypeControllerMap non_blocking_data_type_controllers_;
-
- // Deleter for elements of the non-blocking data types controller map.
- STLValueDeleter<NonBlockingDataTypeControllerMap>
- non_blocking_data_type_controllers_deleter_;
};
} // namespace sync_driver
« no previous file with comments | « components/policy/core/common/schema.cc ('k') | components/sync_driver/non_blocking_data_type_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698