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

Unified Diff: chrome/browser/policy/user_cloud_policy_store_chromeos.cc

Issue 11415094: Split UserCloudPolicyManager implementation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Bring back ProxyPolicyProvider, fix local_state policy provider, fix Joao's fine CloudPolicyTest. Created 8 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/policy/user_cloud_policy_store_chromeos.cc
diff --git a/chrome/browser/policy/user_cloud_policy_store_chromeos.cc b/chrome/browser/policy/user_cloud_policy_store_chromeos.cc
index 850d5aac802ef42dd614bdc5d99d3c76cdb6a5a4..a555a6770633b99e5608d9afa1c77a015b3f03d5 100644
--- a/chrome/browser/policy/user_cloud_policy_store_chromeos.cc
+++ b/chrome/browser/policy/user_cloud_policy_store_chromeos.cc
@@ -182,13 +182,6 @@ void UserCloudPolicyStoreChromeOS::Load() {
weak_factory_.GetWeakPtr()));
}
-void UserCloudPolicyStoreChromeOS::RemoveStoredPolicy() {
- // This should never be called on ChromeOS since it is not possible to sign
- // out of a Profile. The underlying policy store is only removed if the
- // Profile itself is deleted.
- NOTREACHED();
-}
-
void UserCloudPolicyStoreChromeOS::OnPolicyRetrieved(
const std::string& policy_blob) {
if (policy_blob.empty()) {
@@ -358,25 +351,4 @@ void UserCloudPolicyStoreChromeOS::RemoveLegacyCacheDir(const FilePath& dir) {
LOG(ERROR) << "Failed to remove cache dir " << dir.value();
}
-// static
-scoped_ptr<CloudPolicyStore> CloudPolicyStore::CreateUserPolicyStore(
- Profile* profile, bool force_immediate_policy_load) {
- // On ChromeOS, callers should never try to load policy synchronously
- // (profile initialization is always asynchronous).
- DCHECK(!force_immediate_policy_load);
- FilePath profile_dir;
- CHECK(PathService::Get(chrome::DIR_USER_DATA, &profile_dir));
- CommandLine* command_line = CommandLine::ForCurrentProcess();
- const FilePath policy_dir =
- profile_dir
- .Append(command_line->GetSwitchValuePath(switches::kLoginProfile))
- .Append(kPolicyDir);
- const FilePath policy_cache_file = policy_dir.Append(kPolicyCacheFile);
- const FilePath token_cache_file = policy_dir.Append(kTokenCacheFile);
-
- return scoped_ptr<CloudPolicyStore>(new UserCloudPolicyStoreChromeOS(
- chromeos::DBusThreadManager::Get()->GetSessionManagerClient(),
- token_cache_file, policy_cache_file));
-}
-
} // namespace policy

Powered by Google App Engine
This is Rietveld 408576698