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

Side by Side Diff: components/wifi_sync/wifi_credential_syncable_service_factory.cc

Issue 2257793002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/wifi_sync/wifi_credential_syncable_service_factory.h" 5 #include "components/wifi_sync/wifi_credential_syncable_service_factory.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 } 89 }
90 90
91 #if defined(OS_CHROMEOS) 91 #if defined(OS_CHROMEOS)
92 std::unique_ptr<WifiConfigDelegate> 92 std::unique_ptr<WifiConfigDelegate>
93 WifiCredentialSyncableServiceFactory::BuildWifiConfigDelegateChromeOs( 93 WifiCredentialSyncableServiceFactory::BuildWifiConfigDelegateChromeOs(
94 content::BrowserContext* context) const { 94 content::BrowserContext* context) const {
95 // Note: NetworkHandler is a singleton that is managed by 95 // Note: NetworkHandler is a singleton that is managed by
96 // ChromeBrowserMainPartsChromeos, and destroyed after all 96 // ChromeBrowserMainPartsChromeos, and destroyed after all
97 // KeyedService instances are destroyed. 97 // KeyedService instances are destroyed.
98 chromeos::NetworkHandler* network_handler = chromeos::NetworkHandler::Get(); 98 chromeos::NetworkHandler* network_handler = chromeos::NetworkHandler::Get();
99 return base::WrapUnique(new WifiConfigDelegateChromeOs( 99 return base::MakeUnique<WifiConfigDelegateChromeOs>(
100 GetUserHash(context, !ignore_login_state_for_test_), 100 GetUserHash(context, !ignore_login_state_for_test_),
101 network_handler->managed_network_configuration_handler())); 101 network_handler->managed_network_configuration_handler());
102 } 102 }
103 #endif 103 #endif
104 104
105 } // namespace wifi_sync 105 } // namespace wifi_sync
OLDNEW
« no previous file with comments | « components/wifi_sync/wifi_credential.cc ('k') | components/wifi_sync/wifi_credential_syncable_service_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698