OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/installer/util/master_preferences.h" | 5 #include "chrome/installer/util/master_preferences.h" |
6 | 6 |
7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
10 #include "chrome/common/json_value_serializer.h" | 10 #include "chrome/common/json_value_serializer.h" |
(...skipping 10 matching lines...) Expand all Loading... |
21 const wchar_t kAltShortcutText[] = L"alternate_shortcut_text"; | 21 const wchar_t kAltShortcutText[] = L"alternate_shortcut_text"; |
22 const wchar_t kChromeShortcutIconIndex[] = L"chrome_shortcut_icon_index"; | 22 const wchar_t kChromeShortcutIconIndex[] = L"chrome_shortcut_icon_index"; |
23 const wchar_t kCreateAllShortcuts[] = L"create_all_shortcuts"; | 23 const wchar_t kCreateAllShortcuts[] = L"create_all_shortcuts"; |
24 const wchar_t kDistroImportBookmarksPref[] = L"import_bookmarks"; | 24 const wchar_t kDistroImportBookmarksPref[] = L"import_bookmarks"; |
25 const wchar_t kDistroImportHistoryPref[] = L"import_history"; | 25 const wchar_t kDistroImportHistoryPref[] = L"import_history"; |
26 const wchar_t kDistroImportHomePagePref[] = L"import_home_page"; | 26 const wchar_t kDistroImportHomePagePref[] = L"import_home_page"; |
27 const wchar_t kDistroImportSearchPref[] = L"import_search_engine"; | 27 const wchar_t kDistroImportSearchPref[] = L"import_search_engine"; |
28 const wchar_t kDistroPingDelay[] = L"ping_delay"; | 28 const wchar_t kDistroPingDelay[] = L"ping_delay"; |
29 const wchar_t kDistroShowWelcomePage[] = L"show_welcome_page"; | 29 const wchar_t kDistroShowWelcomePage[] = L"show_welcome_page"; |
30 const wchar_t kDistroSkipFirstRunPref[] = L"skip_first_run_ui"; | 30 const wchar_t kDistroSkipFirstRunPref[] = L"skip_first_run_ui"; |
| 31 const wchar_t kDoNotCreateShortcuts[] = L"do_not_create_shortcuts"; |
31 const wchar_t kDoNotLaunchChrome[] = L"do_not_launch_chrome"; | 32 const wchar_t kDoNotLaunchChrome[] = L"do_not_launch_chrome"; |
32 const wchar_t kMakeChromeDefault[] = L"make_chrome_default"; | 33 const wchar_t kMakeChromeDefault[] = L"make_chrome_default"; |
33 const wchar_t kMakeChromeDefaultForUser[] = L"make_chrome_default_for_user"; | 34 const wchar_t kMakeChromeDefaultForUser[] = L"make_chrome_default_for_user"; |
34 const wchar_t kRequireEula[] = L"require_eula"; | 35 const wchar_t kRequireEula[] = L"require_eula"; |
35 const wchar_t kSystemLevel[] = L"system_level"; | 36 const wchar_t kSystemLevel[] = L"system_level"; |
36 const wchar_t kVerboseLogging[] = L"verbose_logging"; | 37 const wchar_t kVerboseLogging[] = L"verbose_logging"; |
37 } | 38 } |
38 | 39 |
39 bool GetDistroBooleanPreference(const DictionaryValue* prefs, | 40 bool GetDistroBooleanPreference(const DictionaryValue* prefs, |
40 const std::wstring& name) { | 41 const std::wstring& name) { |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 if (prefs && !name.empty()) { | 112 if (prefs && !name.empty()) { |
112 std::wstring key(kDistroDict); | 113 std::wstring key(kDistroDict); |
113 key.append(L"." + name); | 114 key.append(L"." + name); |
114 if (prefs->SetBoolean(key, value)) | 115 if (prefs->SetBoolean(key, value)) |
115 ret = true; | 116 ret = true; |
116 } | 117 } |
117 return ret; | 118 return ret; |
118 } | 119 } |
119 | 120 |
120 } // installer_util | 121 } // installer_util |
OLD | NEW |