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 #ifndef CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_ | 5 #ifndef CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_ |
6 #define CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_ | 6 #define CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_ |
7 | 7 |
| 8 namespace base { |
8 class FilePath; | 9 class FilePath; |
| 10 } |
9 | 11 |
10 namespace chrome_launcher_support { | 12 namespace chrome_launcher_support { |
11 | 13 |
12 enum InstallationLevel { | 14 enum InstallationLevel { |
13 USER_LEVEL_INSTALLATION, | 15 USER_LEVEL_INSTALLATION, |
14 SYSTEM_LEVEL_INSTALLATION | 16 SYSTEM_LEVEL_INSTALLATION |
15 }; | 17 }; |
16 | 18 |
17 // Returns the path to an existing setup.exe at the specified level, if it can | 19 // Returns the path to an existing setup.exe at the specified level, if it can |
18 // be found via Omaha client state. | 20 // be found via Omaha client state. |
19 FilePath GetSetupExeForInstallationLevel(InstallationLevel level); | 21 base::FilePath GetSetupExeForInstallationLevel(InstallationLevel level); |
20 | 22 |
21 // Returns the path to an installed chrome.exe at the specified level, if it can | 23 // Returns the path to an installed chrome.exe at the specified level, if it can |
22 // be found via Omaha client state. Prefers the installer from a multi-install, | 24 // be found via Omaha client state. Prefers the installer from a multi-install, |
23 // but may also return that of a single-install of Chrome if no multi-install | 25 // but may also return that of a single-install of Chrome if no multi-install |
24 // exists. | 26 // exists. |
25 FilePath GetChromePathForInstallationLevel(InstallationLevel level); | 27 base::FilePath GetChromePathForInstallationLevel(InstallationLevel level); |
26 | 28 |
27 // Returns the path to an installed app_host.exe at the specified level, if | 29 // Returns the path to an installed app_host.exe at the specified level, if |
28 // it can be found via Omaha client state. | 30 // it can be found via Omaha client state. |
29 FilePath GetAppHostPathForInstallationLevel(InstallationLevel level); | 31 base::FilePath GetAppHostPathForInstallationLevel(InstallationLevel level); |
30 | 32 |
31 // Returns the path to an installed chrome.exe, or an empty path. Prefers a | 33 // Returns the path to an installed chrome.exe, or an empty path. Prefers a |
32 // system-level installation to a user-level installation. Uses Omaha client | 34 // system-level installation to a user-level installation. Uses Omaha client |
33 // state to identify a Chrome installation location. | 35 // state to identify a Chrome installation location. |
34 // In non-official builds, to ease development, this will first look for a | 36 // In non-official builds, to ease development, this will first look for a |
35 // chrome.exe in the same directory as the current executable. | 37 // chrome.exe in the same directory as the current executable. |
36 // The file path returned (if any) is guaranteed to exist. | 38 // The file path returned (if any) is guaranteed to exist. |
37 FilePath GetAnyChromePath(); | 39 base::FilePath GetAnyChromePath(); |
38 | 40 |
39 // Returns the path to an installed app_host.exe, or an empty path. Prefers a | 41 // Returns the path to an installed app_host.exe, or an empty path. Prefers a |
40 // system-level installation to a user-level installation. Uses Omaha client | 42 // system-level installation to a user-level installation. Uses Omaha client |
41 // state to identify a App Host installation location. | 43 // state to identify a App Host installation location. |
42 // In non-official builds, to ease development, this will first look for a | 44 // In non-official builds, to ease development, this will first look for a |
43 // app_host.exe in the same directory as the current executable. | 45 // app_host.exe in the same directory as the current executable. |
44 // The file path returned (if any) is guaranteed to exist. | 46 // The file path returned (if any) is guaranteed to exist. |
45 FilePath GetAnyAppHostPath(); | 47 base::FilePath GetAnyAppHostPath(); |
46 | 48 |
47 // Returns true if App Host is installed (system-level or user-level), | 49 // Returns true if App Host is installed (system-level or user-level), |
48 // or in the same directory as the current executable. | 50 // or in the same directory as the current executable. |
49 bool IsAppHostPresent(); | 51 bool IsAppHostPresent(); |
50 | 52 |
51 // Returns true if App Launcher is installed (system-level or user-level). | 53 // Returns true if App Launcher is installed (system-level or user-level). |
52 bool IsAppLauncherPresent(); | 54 bool IsAppLauncherPresent(); |
53 | 55 |
54 } // namespace chrome_launcher_support | 56 } // namespace chrome_launcher_support |
55 | 57 |
56 #endif // CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_ | 58 #endif // CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_ |
OLD | NEW |