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 declares a class that contains various method related to branding. | 5 // This file declares a class that contains various method related to branding. |
6 | 6 |
7 #ifndef CHROME_INSTALLER_UTIL_BROWSER_DISTRIBUTION_H_ | 7 #ifndef CHROME_INSTALLER_UTIL_BROWSER_DISTRIBUTION_H_ |
8 #define CHROME_INSTALLER_UTIL_BROWSER_DISTRIBUTION_H_ | 8 #define CHROME_INSTALLER_UTIL_BROWSER_DISTRIBUTION_H_ |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 10 matching lines...) Expand all Loading... |
21 #endif | 21 #endif |
22 | 22 |
23 class AppRegistrationData; | 23 class AppRegistrationData; |
24 | 24 |
25 class BrowserDistribution { | 25 class BrowserDistribution { |
26 public: | 26 public: |
27 enum Type { | 27 enum Type { |
28 CHROME_BROWSER, | 28 CHROME_BROWSER, |
29 CHROME_FRAME, | 29 CHROME_FRAME, |
30 CHROME_BINARIES, | 30 CHROME_BINARIES, |
31 CHROME_APP_HOST, | |
32 NUM_TYPES | 31 NUM_TYPES |
33 }; | 32 }; |
34 | 33 |
35 enum ShortcutType { | 34 enum ShortcutType { |
36 SHORTCUT_CHROME, | 35 SHORTCUT_CHROME, |
37 SHORTCUT_CHROME_ALTERNATE, | 36 SHORTCUT_CHROME_ALTERNATE, |
38 SHORTCUT_APP_LAUNCHER | 37 SHORTCUT_APP_LAUNCHER |
39 }; | 38 }; |
40 | 39 |
41 enum Subfolder { | 40 enum Subfolder { |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
143 | 142 |
144 virtual bool CanCreateDesktopShortcuts(); | 143 virtual bool CanCreateDesktopShortcuts(); |
145 | 144 |
146 virtual bool GetChromeChannel(base::string16* channel); | 145 virtual bool GetChromeChannel(base::string16* channel); |
147 | 146 |
148 // Returns true if this distribution includes a DelegateExecute verb handler, | 147 // Returns true if this distribution includes a DelegateExecute verb handler, |
149 // and provides the CommandExecuteImpl class UUID if |handler_class_uuid| is | 148 // and provides the CommandExecuteImpl class UUID if |handler_class_uuid| is |
150 // non-NULL. | 149 // non-NULL. |
151 virtual bool GetCommandExecuteImplClsid(base::string16* handler_class_uuid); | 150 virtual bool GetCommandExecuteImplClsid(base::string16* handler_class_uuid); |
152 | 151 |
153 // Returns true if this distribution uses app_host.exe to run platform apps. | |
154 virtual bool AppHostIsSupported(); | |
155 | |
156 virtual void UpdateInstallStatus(bool system_install, | 152 virtual void UpdateInstallStatus(bool system_install, |
157 installer::ArchiveType archive_type, | 153 installer::ArchiveType archive_type, |
158 installer::InstallStatus install_status); | 154 installer::InstallStatus install_status); |
159 | 155 |
160 // Returns true if this distribution should set the Omaha experiment_labels | 156 // Returns true if this distribution should set the Omaha experiment_labels |
161 // registry value. | 157 // registry value. |
162 virtual bool ShouldSetExperimentLabels(); | 158 virtual bool ShouldSetExperimentLabels(); |
163 | 159 |
164 virtual bool HasUserExperiments(); | 160 virtual bool HasUserExperiments(); |
165 | 161 |
166 protected: | 162 protected: |
167 BrowserDistribution(Type type, scoped_ptr<AppRegistrationData> app_reg_data); | 163 BrowserDistribution(Type type, scoped_ptr<AppRegistrationData> app_reg_data); |
168 | 164 |
169 template<class DistributionClass> | 165 template<class DistributionClass> |
170 static BrowserDistribution* GetOrCreateBrowserDistribution( | 166 static BrowserDistribution* GetOrCreateBrowserDistribution( |
171 BrowserDistribution** dist); | 167 BrowserDistribution** dist); |
172 | 168 |
173 const Type type_; | 169 const Type type_; |
174 | 170 |
175 scoped_ptr<AppRegistrationData> app_reg_data_; | 171 scoped_ptr<AppRegistrationData> app_reg_data_; |
176 | 172 |
177 private: | 173 private: |
178 BrowserDistribution(); | 174 BrowserDistribution(); |
179 | 175 |
180 DISALLOW_COPY_AND_ASSIGN(BrowserDistribution); | 176 DISALLOW_COPY_AND_ASSIGN(BrowserDistribution); |
181 }; | 177 }; |
182 | 178 |
183 #endif // CHROME_INSTALLER_UTIL_BROWSER_DISTRIBUTION_H_ | 179 #endif // CHROME_INSTALLER_UTIL_BROWSER_DISTRIBUTION_H_ |
OLD | NEW |