OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/mock_configuration_policy_provider.h" | 5 #include "chrome/browser/policy/mock_configuration_policy_provider.h" |
6 | 6 |
7 #include "base/stl_util-inl.h" | 7 #include "base/stl_util-inl.h" |
8 #include "chrome/browser/policy/configuration_policy_pref_store.h" | 8 #include "chrome/browser/policy/configuration_policy_pref_store.h" |
9 | 9 |
10 namespace policy { | 10 namespace policy { |
(...skipping 12 matching lines...) Expand all Loading... |
23 std::swap(policy_map_[policy], value); | 23 std::swap(policy_map_[policy], value); |
24 delete value; | 24 delete value; |
25 } | 25 } |
26 | 26 |
27 bool MockConfigurationPolicyProvider::Provide( | 27 bool MockConfigurationPolicyProvider::Provide( |
28 ConfigurationPolicyStoreInterface* store) { | 28 ConfigurationPolicyStoreInterface* store) { |
29 for (PolicyMap::const_iterator current = policy_map_.begin(); | 29 for (PolicyMap::const_iterator current = policy_map_.begin(); |
30 current != policy_map_.end(); ++current) { | 30 current != policy_map_.end(); ++current) { |
31 store->Apply(current->first, current->second->DeepCopy()); | 31 store->Apply(current->first, current->second->DeepCopy()); |
32 } | 32 } |
| 33 store->Completed(); |
33 return true; | 34 return true; |
34 } | 35 } |
35 | 36 |
36 } | 37 } |
OLD | NEW |