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

Unified Diff: services/shell/public/cpp/interface_registry.h

Issue 2259823003: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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: services/shell/public/cpp/interface_registry.h
diff --git a/services/shell/public/cpp/interface_registry.h b/services/shell/public/cpp/interface_registry.h
index 9f1051e09bfbb44440c5363102d33fce8d4e162b..e53f4a20dd4d8a7754ad3d19b06aee4ec185489f 100644
--- a/services/shell/public/cpp/interface_registry.h
+++ b/services/shell/public/cpp/interface_registry.h
@@ -89,8 +89,7 @@ class InterfaceRegistry : public mojom::InterfaceProvider {
template <typename Interface>
bool AddInterface(InterfaceFactory<Interface>* factory) {
return SetInterfaceBinderForName(
- base::WrapUnique(
- new internal::InterfaceFactoryBinder<Interface>(factory)),
+ base::MakeUnique<internal::InterfaceFactoryBinder<Interface>>(factory),
Interface::Name_);
}
@@ -103,8 +102,8 @@ class InterfaceRegistry : public mojom::InterfaceProvider {
const scoped_refptr<base::SingleThreadTaskRunner>& task_runner =
nullptr) {
return SetInterfaceBinderForName(
- base::WrapUnique(
- new internal::CallbackBinder<Interface>(callback, task_runner)),
+ base::MakeUnique<internal::CallbackBinder<Interface>>(callback,
+ task_runner),
Interface::Name_);
}
bool AddInterface(
« no previous file with comments | « services/shell/background/tests/background_shell_unittest.cc ('k') | services/shell/public/cpp/lib/interface_registry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698