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

Side by Side Diff: trunk/src/chrome/installer/launcher_support/chrome_launcher_support.h

Issue 422593002: Revert 285661 "Remove some dead app host code." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 4 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) 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 namespace base {
9 class FilePath; 9 class FilePath;
10 } 10 }
11 11
12 namespace chrome_launcher_support { 12 namespace chrome_launcher_support {
13 13
14 enum InstallationLevel { 14 enum InstallationLevel {
15 USER_LEVEL_INSTALLATION, 15 USER_LEVEL_INSTALLATION,
16 SYSTEM_LEVEL_INSTALLATION, 16 SYSTEM_LEVEL_INSTALLATION,
17 }; 17 };
18 18
19 enum InstallationState {
20 NOT_INSTALLED,
21 INSTALLED_AT_USER_LEVEL,
22 INSTALLED_AT_SYSTEM_LEVEL,
23 };
24
25 // The app GUID for Chrome App Launcher.
26 extern const wchar_t kAppLauncherGuid[];
27
28 // Returns the path to an existing setup.exe at the specified level, if it can
29 // be found via Omaha client state.
30 base::FilePath GetSetupExeForInstallationLevel(InstallationLevel level);
31
19 // Returns the path to an installed chrome.exe at the specified level, if it can 32 // Returns the path to an installed chrome.exe at the specified level, if it can
20 // be found via Omaha client state. Prefers the installer from a multi-install, 33 // be found via Omaha client state. Prefers the installer from a multi-install,
21 // but may also return that of a single-install of Chrome if no multi-install 34 // but may also return that of a single-install of Chrome if no multi-install
22 // exists. 35 // exists.
23 base::FilePath GetChromePathForInstallationLevel(InstallationLevel level); 36 base::FilePath GetChromePathForInstallationLevel(InstallationLevel level);
24 37
38 // Returns the path to an installed app_host.exe at the specified level, if
39 // it can be found via Omaha client state.
40 base::FilePath GetAppHostPathForInstallationLevel(InstallationLevel level);
41
42 // Returns the path to an installed SxS chrome.exe at the specified level, if
43 // it can be found via Omaha client state.
44 base::FilePath GetChromeSxSPathForInstallationLevel(InstallationLevel level);
45
25 // Returns the path to an installed chrome.exe, or an empty path. Prefers a 46 // Returns the path to an installed chrome.exe, or an empty path. Prefers a
26 // system-level installation to a user-level installation. Uses Omaha client 47 // system-level installation to a user-level installation. Uses Omaha client
27 // state to identify a Chrome installation location. 48 // state to identify a Chrome installation location.
28 // The file path returned (if any) is guaranteed to exist. 49 // The file path returned (if any) is guaranteed to exist.
29 base::FilePath GetAnyChromePath(); 50 base::FilePath GetAnyChromePath();
30 51
52 // Returns the path to an installed app_host.exe, or an empty path. Prefers a
53 // system-level installation to a user-level installation. Uses Omaha client
54 // state to identify a App Host installation location.
55 // The file path returned (if any) is guaranteed to exist.
56 base::FilePath GetAnyAppHostPath();
57
58 // Returns the path to an installed SxS chrome.exe, or an empty path. Prefers a
59 // user-level installation to a system-level installation. Uses Omaha client
60 // state to identify a Chrome Canary installation location.
61 // The file path returned (if any) is guaranteed to exist.
62 base::FilePath GetAnyChromeSxSPath();
63
64 // Uninstalls the legacy app launcher by launching setup.exe with the uninstall
65 // arguments from the App Launcher ClientState registry key. The uninstall will
66 // run asynchronously.
67 void UninstallLegacyAppLauncher(InstallationLevel level);
68
69 // Returns true if App Host is installed (system-level or user-level),
70 // or in the same directory as the current executable.
71 bool IsAppHostPresent();
72
73 // Returns the app launcher installation state. If the launcher is installed
74 // at both system level and user level, system level is returned.
75 InstallationState GetAppLauncherInstallationState();
76
77 // Returns true if App Launcher is installed (system-level or user-level).
78 bool IsAppLauncherPresent();
79
80 // Returns true if the Chrome browser is installed (system-level or user-level).
81 // If this is running in an official build, it will check if a non-canary build
82 // if installed. If it is not an official build, it will always return true.
83 bool IsChromeBrowserPresent();
84
31 } // namespace chrome_launcher_support 85 } // namespace chrome_launcher_support
32 86
33 #endif // CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_ 87 #endif // CHROME_INSTALLER_LAUNCHER_SUPPORT_CHROME_LAUNCHER_SUPPORT_H_
OLDNEW
« no previous file with comments | « trunk/src/chrome/chrome_installer.gypi ('k') | trunk/src/chrome/installer/launcher_support/chrome_launcher_support.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698