OLD | NEW |
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.h" | 5 #include "chrome/browser/policy/profile_policy_connector.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/values.h" | 9 #include "base/values.h" |
| 10 #include "build/build_config.h" |
10 #include "chrome/browser/browser_process.h" | 11 #include "chrome/browser/browser_process.h" |
11 #include "components/policy/core/browser/browser_policy_connector.h" | 12 #include "components/policy/core/browser/browser_policy_connector.h" |
12 #include "components/policy/core/common/cloud/cloud_policy_core.h" | 13 #include "components/policy/core/common/cloud/cloud_policy_core.h" |
13 #include "components/policy/core/common/cloud/cloud_policy_manager.h" | 14 #include "components/policy/core/common/cloud/cloud_policy_manager.h" |
14 #include "components/policy/core/common/cloud/cloud_policy_store.h" | 15 #include "components/policy/core/common/cloud/cloud_policy_store.h" |
15 #include "components/policy/core/common/configuration_policy_provider.h" | 16 #include "components/policy/core/common/configuration_policy_provider.h" |
16 #include "components/policy/core/common/policy_bundle.h" | 17 #include "components/policy/core/common/policy_bundle.h" |
17 #include "components/policy/core/common/policy_map.h" | 18 #include "components/policy/core/common/policy_map.h" |
18 #include "components/policy/core/common/policy_namespace.h" | 19 #include "components/policy/core/common/policy_namespace.h" |
19 #include "components/policy/core/common/policy_service_impl.h" | 20 #include "components/policy/core/common/policy_service_impl.h" |
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
187 const char* name) const { | 188 const char* name) const { |
188 const PolicyNamespace chrome_ns(POLICY_DOMAIN_CHROME, ""); | 189 const PolicyNamespace chrome_ns(POLICY_DOMAIN_CHROME, ""); |
189 for (const ConfigurationPolicyProvider* provider : policy_providers_) { | 190 for (const ConfigurationPolicyProvider* provider : policy_providers_) { |
190 if (provider->policies().Get(chrome_ns).Get(name)) | 191 if (provider->policies().Get(chrome_ns).Get(name)) |
191 return provider; | 192 return provider; |
192 } | 193 } |
193 return nullptr; | 194 return nullptr; |
194 } | 195 } |
195 | 196 |
196 } // namespace policy | 197 } // namespace policy |
OLD | NEW |