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

Side by Side Diff: chrome/installer/util/master_preferences.cc

Issue 1525042: Additional changes to support Chrome / CF installation wrapped in an MSI:... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 8 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
OLDNEW
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 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 #if defined(OS_WIN) 107 #if defined(OS_WIN)
108 if (cmd_line.HasSwitch(installer_util::switches::kInstallerData)) { 108 if (cmd_line.HasSwitch(installer_util::switches::kInstallerData)) {
109 FilePath prefs_path( 109 FilePath prefs_path(
110 cmd_line.GetSwitchValue(installer_util::switches::kInstallerData)); 110 cmd_line.GetSwitchValue(installer_util::switches::kInstallerData));
111 prefs = installer_util::ParseDistributionPreferences(prefs_path); 111 prefs = installer_util::ParseDistributionPreferences(prefs_path);
112 } 112 }
113 113
114 if (!prefs) 114 if (!prefs)
115 prefs = new DictionaryValue(); 115 prefs = new DictionaryValue();
116 116
117 if (cmd_line.HasSwitch(installer_util::switches::kChromeFrame))
118 installer_util::SetDistroBooleanPreference(
119 prefs, installer_util::master_preferences::kChromeFrame, true);
120
117 if (cmd_line.HasSwitch(installer_util::switches::kCreateAllShortcuts)) 121 if (cmd_line.HasSwitch(installer_util::switches::kCreateAllShortcuts))
118 installer_util::SetDistroBooleanPreference( 122 installer_util::SetDistroBooleanPreference(
119 prefs, installer_util::master_preferences::kCreateAllShortcuts, true); 123 prefs, installer_util::master_preferences::kCreateAllShortcuts, true);
120 124
121 if (cmd_line.HasSwitch(installer_util::switches::kDoNotCreateShortcuts)) 125 if (cmd_line.HasSwitch(installer_util::switches::kDoNotCreateShortcuts))
122 installer_util::SetDistroBooleanPreference( 126 installer_util::SetDistroBooleanPreference(
123 prefs, installer_util::master_preferences::kDoNotCreateShortcuts, true); 127 prefs, installer_util::master_preferences::kDoNotCreateShortcuts, true);
124 128
125 if (cmd_line.HasSwitch(installer_util::switches::kMsi)) 129 if (cmd_line.HasSwitch(installer_util::switches::kMsi))
126 installer_util::SetDistroBooleanPreference( 130 installer_util::SetDistroBooleanPreference(
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 return true; 197 return true;
194 } 198 }
195 199
196 bool HasExtensionsBlock(const DictionaryValue* prefs, 200 bool HasExtensionsBlock(const DictionaryValue* prefs,
197 DictionaryValue** extensions) { 201 DictionaryValue** extensions) {
198 return (prefs->GetDictionary(master_preferences::kExtensionsBlock, 202 return (prefs->GetDictionary(master_preferences::kExtensionsBlock,
199 extensions)); 203 extensions));
200 } 204 }
201 205
202 } // installer_util 206 } // installer_util
OLDNEW
« no previous file with comments | « chrome/installer/util/install_util.cc ('k') | chrome/installer/util/master_preferences_constants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698