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

Side by Side Diff: chrome/browser/policy/profile_policy_connector_factory.cc

Issue 2945023002: Introduce profile for lock screen apps (Closed)
Patch Set: rebase Created 3 years, 5 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/policy/profile_policy_connector_factory.h" 5 #include "chrome/browser/policy/profile_policy_connector_factory.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/singleton.h" 10 #include "base/memory/singleton.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 100
101 const user_manager::User* user = nullptr; 101 const user_manager::User* user = nullptr;
102 SchemaRegistry* schema_registry = 102 SchemaRegistry* schema_registry =
103 SchemaRegistryServiceFactory::GetForContext(context)->registry(); 103 SchemaRegistryServiceFactory::GetForContext(context)->registry();
104 104
105 ConfigurationPolicyProvider* policy_provider = nullptr; 105 ConfigurationPolicyProvider* policy_provider = nullptr;
106 const CloudPolicyStore* policy_store = nullptr; 106 const CloudPolicyStore* policy_store = nullptr;
107 107
108 #if defined(OS_CHROMEOS) 108 #if defined(OS_CHROMEOS)
109 Profile* const profile = Profile::FromBrowserContext(context); 109 Profile* const profile = Profile::FromBrowserContext(context);
110 if (!chromeos::ProfileHelper::IsSigninProfile(profile)) { 110 if (!chromeos::ProfileHelper::IsSigninProfile(profile) &&
111 !chromeos::ProfileHelper::IsLockScreenAppProfile(profile)) {
111 user = chromeos::ProfileHelper::Get()->GetUserByProfile(profile); 112 user = chromeos::ProfileHelper::Get()->GetUserByProfile(profile);
112 CHECK(user); 113 CHECK(user);
113 } 114 }
114 115
115 CloudPolicyManager* user_cloud_policy_manager = 116 CloudPolicyManager* user_cloud_policy_manager =
116 UserPolicyManagerFactoryChromeOS::GetCloudPolicyManagerForProfile( 117 UserPolicyManagerFactoryChromeOS::GetCloudPolicyManagerForProfile(
117 profile); 118 profile);
118 ActiveDirectoryPolicyManager* active_directory_manager = 119 ActiveDirectoryPolicyManager* active_directory_manager =
119 UserPolicyManagerFactoryChromeOS:: 120 UserPolicyManagerFactoryChromeOS::
120 GetActiveDirectoryPolicyManagerForProfile(profile); 121 GetActiveDirectoryPolicyManagerForProfile(profile);
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 175
175 bool ProfilePolicyConnectorFactory::HasTestingFactory( 176 bool ProfilePolicyConnectorFactory::HasTestingFactory(
176 content::BrowserContext* context) { 177 content::BrowserContext* context) {
177 return false; 178 return false;
178 } 179 }
179 180
180 void ProfilePolicyConnectorFactory::CreateServiceNow( 181 void ProfilePolicyConnectorFactory::CreateServiceNow(
181 content::BrowserContext* context) {} 182 content::BrowserContext* context) {}
182 183
183 } // namespace policy 184 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/policy/profile_policy_connector.cc ('k') | chrome/browser/profiles/profile_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698