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

Side by Side Diff: chrome/browser/policy/configuration_policy_pref_store.cc

Issue 7634018: base: Rename ValueType to something less redundant as _just_ Type. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « base/values.cc ('k') | chrome/browser/policy/configuration_policy_provider.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/configuration_policy_pref_store.h" 5 #include "chrome/browser/policy/configuration_policy_pref_store.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 std::vector<std::string>* differing_prefs) const; 50 std::vector<std::string>* differing_prefs) const;
51 51
52 private: 52 private:
53 // ConfigurationPolicyStore methods: 53 // ConfigurationPolicyStore methods:
54 virtual void Apply(ConfigurationPolicyType setting, Value* value); 54 virtual void Apply(ConfigurationPolicyType setting, Value* value);
55 55
56 // Policies that map to a single preference are handled 56 // Policies that map to a single preference are handled
57 // by an automated converter. Each one of these policies 57 // by an automated converter. Each one of these policies
58 // has an entry in |simple_policy_map_| with the following type. 58 // has an entry in |simple_policy_map_| with the following type.
59 struct PolicyToPreferenceMapEntry { 59 struct PolicyToPreferenceMapEntry {
60 Value::ValueType value_type; 60 base::Value::Type value_type;
61 ConfigurationPolicyType policy_type; 61 ConfigurationPolicyType policy_type;
62 const char* preference_path; // A DictionaryValue path, not a file path. 62 const char* preference_path; // A DictionaryValue path, not a file path.
63 }; 63 };
64 64
65 // Remove the preferences found in the map from |prefs_|. Returns true if any 65 // Remove the preferences found in the map from |prefs_|. Returns true if any
66 // such preferences were found and removed. 66 // such preferences were found and removed.
67 bool RemovePreferencesOfMap(const PolicyToPreferenceMapEntry* map, 67 bool RemovePreferencesOfMap(const PolicyToPreferenceMapEntry* map,
68 int table_size); 68 int table_size);
69 69
70 bool ApplyPolicyFromMap(ConfigurationPolicyType policy, 70 bool ApplyPolicyFromMap(ConfigurationPolicyType policy,
(...skipping 1135 matching lines...) Expand 10 before | Expand all | Expand 10 after
1206 // Update the initialization flag. 1206 // Update the initialization flag.
1207 if (!initialization_complete_ && 1207 if (!initialization_complete_ &&
1208 provider_->IsInitializationComplete()) { 1208 provider_->IsInitializationComplete()) {
1209 initialization_complete_ = true; 1209 initialization_complete_ = true;
1210 FOR_EACH_OBSERVER(PrefStore::Observer, observers_, 1210 FOR_EACH_OBSERVER(PrefStore::Observer, observers_,
1211 OnInitializationCompleted(true)); 1211 OnInitializationCompleted(true));
1212 } 1212 }
1213 } 1213 }
1214 1214
1215 } // namespace policy 1215 } // namespace policy
OLDNEW
« no previous file with comments | « base/values.cc ('k') | chrome/browser/policy/configuration_policy_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698