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

Side by Side Diff: chrome/browser/chromeos/policy/user_network_configuration_updater_factory.cc

Issue 1308823002: Move Singleton and related structs to namespace base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "chrome/browser/chromeos/policy/user_network_configuration_updater_fact ory.h" 5 #include "chrome/browser/chromeos/policy/user_network_configuration_updater_fact ory.h"
6 6
7 #include "base/memory/singleton.h" 7 #include "base/memory/singleton.h"
8 #include "chrome/browser/chromeos/policy/user_network_configuration_updater.h" 8 #include "chrome/browser/chromeos/policy/user_network_configuration_updater.h"
9 #include "chrome/browser/chromeos/profiles/profile_helper.h" 9 #include "chrome/browser/chromeos/profiles/profile_helper.h"
10 #include "chrome/browser/policy/profile_policy_connector.h" 10 #include "chrome/browser/policy/profile_policy_connector.h"
(...skipping 11 matching lines...) Expand all
22 // static 22 // static
23 UserNetworkConfigurationUpdater* 23 UserNetworkConfigurationUpdater*
24 UserNetworkConfigurationUpdaterFactory::GetForProfile(Profile* profile) { 24 UserNetworkConfigurationUpdaterFactory::GetForProfile(Profile* profile) {
25 return static_cast<UserNetworkConfigurationUpdater*>( 25 return static_cast<UserNetworkConfigurationUpdater*>(
26 GetInstance()->GetServiceForBrowserContext(profile, true)); 26 GetInstance()->GetServiceForBrowserContext(profile, true));
27 } 27 }
28 28
29 // static 29 // static
30 UserNetworkConfigurationUpdaterFactory* 30 UserNetworkConfigurationUpdaterFactory*
31 UserNetworkConfigurationUpdaterFactory::GetInstance() { 31 UserNetworkConfigurationUpdaterFactory::GetInstance() {
32 return Singleton<UserNetworkConfigurationUpdaterFactory>::get(); 32 return base::Singleton<UserNetworkConfigurationUpdaterFactory>::get();
33 } 33 }
34 34
35 UserNetworkConfigurationUpdaterFactory::UserNetworkConfigurationUpdaterFactory() 35 UserNetworkConfigurationUpdaterFactory::UserNetworkConfigurationUpdaterFactory()
36 : BrowserContextKeyedServiceFactory( 36 : BrowserContextKeyedServiceFactory(
37 "UserNetworkConfigurationUpdater", 37 "UserNetworkConfigurationUpdater",
38 BrowserContextDependencyManager::GetInstance()) { 38 BrowserContextDependencyManager::GetInstance()) {
39 DependsOn(ProfilePolicyConnectorFactory::GetInstance()); 39 DependsOn(ProfilePolicyConnectorFactory::GetInstance());
40 } 40 }
41 41
42 UserNetworkConfigurationUpdaterFactory:: 42 UserNetworkConfigurationUpdaterFactory::
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 return UserNetworkConfigurationUpdater::CreateForUserPolicy( 80 return UserNetworkConfigurationUpdater::CreateForUserPolicy(
81 profile, 81 profile,
82 allow_trusted_certs_from_policy, 82 allow_trusted_certs_from_policy,
83 *user, 83 *user,
84 profile_connector->policy_service(), 84 profile_connector->policy_service(),
85 chromeos::NetworkHandler::Get()->managed_network_configuration_handler()) 85 chromeos::NetworkHandler::Get()->managed_network_configuration_handler())
86 .release(); 86 .release();
87 } 87 }
88 88
89 } // namespace policy 89 } // namespace policy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698