| 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 "components/policy/core/common/policy_service_impl.h" | 5 #include "components/policy/core/common/policy_service_impl.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <utility> | 10 #include <utility> |
| 11 | 11 |
| 12 #include "base/bind.h" | 12 #include "base/bind.h" |
| 13 #include "base/location.h" | 13 #include "base/location.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #include "base/single_thread_task_runner.h" | 15 #include "base/single_thread_task_runner.h" |
| 16 #include "base/stl_util.h" | 16 #include "base/stl_util.h" |
| 17 #include "base/thread_task_runner_handle.h" | 17 #include "base/threading/thread_task_runner_handle.h" |
| 18 #include "base/values.h" | 18 #include "base/values.h" |
| 19 #include "components/policy/core/common/policy_bundle.h" | 19 #include "components/policy/core/common/policy_bundle.h" |
| 20 #include "components/policy/core/common/policy_map.h" | 20 #include "components/policy/core/common/policy_map.h" |
| 21 #include "components/policy/core/common/policy_types.h" | 21 #include "components/policy/core/common/policy_types.h" |
| 22 #include "policy/policy_constants.h" | 22 #include "policy/policy_constants.h" |
| 23 | 23 |
| 24 namespace policy { | 24 namespace policy { |
| 25 | 25 |
| 26 typedef PolicyServiceImpl::Providers::const_iterator Iterator; | 26 typedef PolicyServiceImpl::Providers::const_iterator Iterator; |
| 27 | 27 |
| (...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 280 if (refresh_pending_.empty() && !refresh_callbacks_.empty()) { | 280 if (refresh_pending_.empty() && !refresh_callbacks_.empty()) { |
| 281 std::vector<base::Closure> callbacks; | 281 std::vector<base::Closure> callbacks; |
| 282 callbacks.swap(refresh_callbacks_); | 282 callbacks.swap(refresh_callbacks_); |
| 283 std::vector<base::Closure>::iterator it; | 283 std::vector<base::Closure>::iterator it; |
| 284 for (it = callbacks.begin(); it != callbacks.end(); ++it) | 284 for (it = callbacks.begin(); it != callbacks.end(); ++it) |
| 285 it->Run(); | 285 it->Run(); |
| 286 } | 286 } |
| 287 } | 287 } |
| 288 | 288 |
| 289 } // namespace policy | 289 } // namespace policy |
| OLD | NEW |