| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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/extensions/standard_management_policy_provider.h" | 5 #include "chrome/browser/extensions/standard_management_policy_provider.h" |
| 6 | 6 |
| 7 #include "base/prefs/pref_service.h" | 7 #include "base/prefs/pref_service.h" |
| 8 #include "chrome/browser/extensions/blacklist.h" | 8 #include "chrome/browser/extensions/blacklist.h" |
| 9 #include "chrome/common/pref_names.h" | 9 #include "chrome/common/pref_names.h" |
| 10 #include "extensions/browser/admin_policy.h" | 10 #include "extensions/browser/admin_policy.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 #ifdef NDEBUG | 27 #ifdef NDEBUG |
| 28 NOTREACHED(); | 28 NOTREACHED(); |
| 29 return std::string(); | 29 return std::string(); |
| 30 #else | 30 #else |
| 31 return "admin policy black/white/forcelist, via the ExtensionPrefs"; | 31 return "admin policy black/white/forcelist, via the ExtensionPrefs"; |
| 32 #endif | 32 #endif |
| 33 } | 33 } |
| 34 | 34 |
| 35 bool StandardManagementPolicyProvider::UserMayLoad( | 35 bool StandardManagementPolicyProvider::UserMayLoad( |
| 36 const Extension* extension, | 36 const Extension* extension, |
| 37 int install_flags, |
| 37 base::string16* error) const { | 38 base::string16* error) const { |
| 38 PrefService* pref_service = prefs_->pref_service(); | 39 PrefService* pref_service = prefs_->pref_service(); |
| 39 | 40 |
| 40 const base::ListValue* blacklist = | 41 const base::ListValue* blacklist = |
| 41 pref_service->GetList(pref_names::kInstallDenyList); | 42 pref_service->GetList(pref_names::kInstallDenyList); |
| 42 const base::ListValue* whitelist = | 43 const base::ListValue* whitelist = |
| 43 pref_service->GetList(pref_names::kInstallAllowList); | 44 pref_service->GetList(pref_names::kInstallAllowList); |
| 44 const base::DictionaryValue* forcelist = | 45 const base::DictionaryValue* forcelist = |
| 45 pref_service->GetDictionary(pref_names::kInstallForceList); | 46 pref_service->GetDictionary(pref_names::kInstallForceList); |
| 46 const base::ListValue* allowed_types = NULL; | 47 const base::ListValue* allowed_types = NULL; |
| (...skipping 10 matching lines...) Expand all Loading... |
| 57 return admin_policy::UserMayModifySettings(extension, error); | 58 return admin_policy::UserMayModifySettings(extension, error); |
| 58 } | 59 } |
| 59 | 60 |
| 60 bool StandardManagementPolicyProvider::MustRemainEnabled( | 61 bool StandardManagementPolicyProvider::MustRemainEnabled( |
| 61 const Extension* extension, | 62 const Extension* extension, |
| 62 base::string16* error) const { | 63 base::string16* error) const { |
| 63 return admin_policy::MustRemainEnabled(extension, error); | 64 return admin_policy::MustRemainEnabled(extension, error); |
| 64 } | 65 } |
| 65 | 66 |
| 66 } // namespace extensions | 67 } // namespace extensions |
| OLD | NEW |