| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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/policy/user_cloud_policy_store_chromeos.h" | 5 #include "chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| 11 #include "base/callback.h" | 11 #include "base/callback.h" |
| 12 #include "base/file_util.h" | 12 #include "base/file_util.h" |
| 13 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
| 14 #include "chrome/browser/policy/cloud/user_policy_disk_cache.h" |
| 15 #include "chrome/browser/policy/cloud/user_policy_token_loader.h" |
| 14 #include "chrome/browser/policy/proto/cloud_policy.pb.h" | 16 #include "chrome/browser/policy/proto/cloud_policy.pb.h" |
| 15 #include "chrome/browser/policy/proto/device_management_local.pb.h" | 17 #include "chrome/browser/policy/proto/device_management_local.pb.h" |
| 16 #include "chrome/browser/policy/user_policy_disk_cache.h" | |
| 17 #include "chrome/browser/policy/user_policy_token_loader.h" | |
| 18 #include "chromeos/dbus/session_manager_client.h" | 18 #include "chromeos/dbus/session_manager_client.h" |
| 19 #include "content/public/browser/browser_thread.h" | 19 #include "content/public/browser/browser_thread.h" |
| 20 #include "google_apis/gaia/gaia_auth_util.h" | 20 #include "google_apis/gaia/gaia_auth_util.h" |
| 21 | 21 |
| 22 namespace em = enterprise_management; | 22 namespace em = enterprise_management; |
| 23 | 23 |
| 24 namespace policy { | 24 namespace policy { |
| 25 | 25 |
| 26 namespace { | 26 namespace { |
| 27 // Subdirectory in the user's profile for storing user policies. | 27 // Subdirectory in the user's profile for storing user policies. |
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 340 NotifyStoreLoaded(); | 340 NotifyStoreLoaded(); |
| 341 } | 341 } |
| 342 | 342 |
| 343 // static | 343 // static |
| 344 void UserCloudPolicyStoreChromeOS::RemoveLegacyCacheDir(const FilePath& dir) { | 344 void UserCloudPolicyStoreChromeOS::RemoveLegacyCacheDir(const FilePath& dir) { |
| 345 if (file_util::PathExists(dir) && !file_util::Delete(dir, true)) | 345 if (file_util::PathExists(dir) && !file_util::Delete(dir, true)) |
| 346 LOG(ERROR) << "Failed to remove cache dir " << dir.value(); | 346 LOG(ERROR) << "Failed to remove cache dir " << dir.value(); |
| 347 } | 347 } |
| 348 | 348 |
| 349 } // namespace policy | 349 } // namespace policy |
| OLD | NEW |