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 // This file contains functions processing master preference file used by | 5 // This file contains functions processing master preference file used by |
6 // setup and first run. | 6 // setup and first run. |
7 | 7 |
8 #ifndef CHROME_INSTALLER_UTIL_MASTER_PREFERENCES_H_ | 8 #ifndef CHROME_INSTALLER_UTIL_MASTER_PREFERENCES_H_ |
9 #define CHROME_INSTALLER_UTIL_MASTER_PREFERENCES_H_ | 9 #define CHROME_INSTALLER_UTIL_MASTER_PREFERENCES_H_ |
10 | 10 |
| 11 #include <memory> |
11 #include <string> | 12 #include <string> |
12 #include <vector> | 13 #include <vector> |
13 | 14 |
14 #include "base/command_line.h" | 15 #include "base/command_line.h" |
15 #include "base/macros.h" | 16 #include "base/macros.h" |
16 #include "base/memory/scoped_ptr.h" | |
17 #include "build/build_config.h" | 17 #include "build/build_config.h" |
18 | 18 |
19 namespace base { | 19 namespace base { |
20 class DictionaryValue; | 20 class DictionaryValue; |
21 class FilePath; | 21 class FilePath; |
22 } | 22 } |
23 | 23 |
24 namespace installer { | 24 namespace installer { |
25 | 25 |
26 #if !defined(OS_MACOSX) | 26 #if !defined(OS_MACOSX) |
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
201 | 201 |
202 // Enforces legacy preferences that should no longer be used, but could be | 202 // Enforces legacy preferences that should no longer be used, but could be |
203 // found in older master_preferences files. | 203 // found in older master_preferences files. |
204 void EnforceLegacyPreferences(); | 204 void EnforceLegacyPreferences(); |
205 | 205 |
206 // Removes the specified string pref from the master preferences and returns | 206 // Removes the specified string pref from the master preferences and returns |
207 // its value. Should be used for master prefs that shouldn't be automatically | 207 // its value. Should be used for master prefs that shouldn't be automatically |
208 // copied over to profile preferences. | 208 // copied over to profile preferences. |
209 std::string ExtractPrefString(const std::string& name) const; | 209 std::string ExtractPrefString(const std::string& name) const; |
210 | 210 |
211 scoped_ptr<base::DictionaryValue> master_dictionary_; | 211 std::unique_ptr<base::DictionaryValue> master_dictionary_; |
212 base::DictionaryValue* distribution_; | 212 base::DictionaryValue* distribution_; |
213 bool preferences_read_from_file_; | 213 bool preferences_read_from_file_; |
214 bool chrome_; | 214 bool chrome_; |
215 bool multi_install_; | 215 bool multi_install_; |
216 | 216 |
217 private: | 217 private: |
218 DISALLOW_COPY_AND_ASSIGN(MasterPreferences); | 218 DISALLOW_COPY_AND_ASSIGN(MasterPreferences); |
219 }; | 219 }; |
220 | 220 |
221 } // namespace installer | 221 } // namespace installer |
222 | 222 |
223 #endif // CHROME_INSTALLER_UTIL_MASTER_PREFERENCES_H_ | 223 #endif // CHROME_INSTALLER_UTIL_MASTER_PREFERENCES_H_ |
OLD | NEW |