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 utility functions for the installer. The original reason | 5 // This file declares utility functions for the installer. The original reason |
6 // for putting these functions in installer\util library is so that we can | 6 // for putting these functions in installer\util library is so that we can |
7 // separate out the critical logic and write unit tests for it. | 7 // separate out the critical logic and write unit tests for it. |
8 | 8 |
9 #ifndef CHROME_INSTALLER_UTIL_INSTALL_UTIL_H_ | 9 #ifndef CHROME_INSTALLER_UTIL_INSTALL_UTIL_H_ |
10 #define CHROME_INSTALLER_UTIL_INSTALL_UTIL_H_ | 10 #define CHROME_INSTALLER_UTIL_INSTALL_UTIL_H_ |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 // important security fix. | 65 // important security fix. |
66 // system_install: if true, looks for version number under the HKLM root, | 66 // system_install: if true, looks for version number under the HKLM root, |
67 // otherwise looks under the HKCU. | 67 // otherwise looks under the HKCU. |
68 static void GetCriticalUpdateVersion(BrowserDistribution* dist, | 68 static void GetCriticalUpdateVersion(BrowserDistribution* dist, |
69 bool system_install, | 69 bool system_install, |
70 base::Version* version); | 70 base::Version* version); |
71 | 71 |
72 // This function checks if the current OS is supported for Chromium. | 72 // This function checks if the current OS is supported for Chromium. |
73 static bool IsOSSupported(); | 73 static bool IsOSSupported(); |
74 | 74 |
75 // Adds work items to |install_list|, which should be a | 75 // Adds work items to |install_list| to set installer error information in the |
76 // NoRollbackWorkItemList, to set installer error information in the registry | 76 // registry for consumption by Google Update. |install_list| must be best- |
77 // for consumption by Google Update. |state_key| must be the full path to an | 77 // effort with rollback disabled. |state_key| must be the full path to an |
78 // app's ClientState key. See InstallerState::WriteInstallerResult for more | 78 // app's ClientState key. See InstallerState::WriteInstallerResult for more |
79 // details. | 79 // details. |
80 static void AddInstallerResultItems(bool system_install, | 80 static void AddInstallerResultItems(bool system_install, |
81 const base::string16& state_key, | 81 const base::string16& state_key, |
82 installer::InstallStatus status, | 82 installer::InstallStatus status, |
83 int string_resource_id, | 83 int string_resource_id, |
84 const base::string16* const launch_cmd, | 84 const base::string16* const launch_cmd, |
85 WorkItemList* install_list); | 85 WorkItemList* install_list); |
86 | 86 |
87 // Update the installer stage reported by Google Update. |state_key_path| | 87 // Update the installer stage reported by Google Update. |state_key_path| |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
222 private: | 222 private: |
223 DISALLOW_COPY_AND_ASSIGN(ProgramCompare); | 223 DISALLOW_COPY_AND_ASSIGN(ProgramCompare); |
224 }; // class ProgramCompare | 224 }; // class ProgramCompare |
225 | 225 |
226 private: | 226 private: |
227 DISALLOW_COPY_AND_ASSIGN(InstallUtil); | 227 DISALLOW_COPY_AND_ASSIGN(InstallUtil); |
228 }; | 228 }; |
229 | 229 |
230 | 230 |
231 #endif // CHROME_INSTALLER_UTIL_INSTALL_UTIL_H_ | 231 #endif // CHROME_INSTALLER_UTIL_INSTALL_UTIL_H_ |
OLD | NEW |