| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/util_constants.h" | 5 #include "chrome/installer/util/util_constants.h" |
| 6 | 6 |
| 7 namespace installer_util { | 7 namespace installer_util { |
| 8 | 8 |
| 9 namespace switches { | 9 namespace switches { |
| 10 | 10 |
| 11 // Install CEEE. | 11 // Install CEEE. |
| 12 const wchar_t kCeee[] = L"ceee"; | 12 const char kCeee[] = "ceee"; |
| 13 | 13 |
| 14 // Install Chrome. | 14 // Install Chrome. |
| 15 // Currently this is only required when used in combination with kMultiInstall. | 15 // Currently this is only required when used in combination with kMultiInstall. |
| 16 const wchar_t kChrome[] = L"chrome"; | 16 const char kChrome[] = "chrome"; |
| 17 | 17 |
| 18 // Run the installer in Chrome Frame mode. | 18 // Run the installer in Chrome Frame mode. |
| 19 const wchar_t kChromeFrame[] = L"chrome-frame"; | 19 const char kChromeFrame[] = "chrome-frame"; |
| 20 | 20 |
| 21 // Run the installer for Chrome SxS. | 21 // Run the installer for Chrome SxS. |
| 22 const wchar_t kChromeSxS[] = L"chrome-sxs"; | 22 const char kChromeSxS[] = "chrome-sxs"; |
| 23 | 23 |
| 24 // Create Desktop and QuickLaunch shortcuts | 24 // Create Desktop and QuickLaunch shortcuts |
| 25 const wchar_t kCreateAllShortcuts[] = L"create-all-shortcuts"; | 25 const char kCreateAllShortcuts[] = "create-all-shortcuts"; |
| 26 | 26 |
| 27 // Delete user profile data. This param is useful only when specified with | 27 // Delete user profile data. This param is useful only when specified with |
| 28 // kUninstall, otherwise it is silently ignored. | 28 // kUninstall, otherwise it is silently ignored. |
| 29 const wchar_t kDeleteProfile[] = L"delete-profile"; | 29 const char kDeleteProfile[] = "delete-profile"; |
| 30 | 30 |
| 31 // Disable logging | 31 // Disable logging |
| 32 const wchar_t kDisableLogging[] = L"disable-logging"; | 32 const char kDisableLogging[] = "disable-logging"; |
| 33 | 33 |
| 34 // Prevent installer from creating desktop shortcuts. | 34 // Prevent installer from creating desktop shortcuts. |
| 35 const wchar_t kDoNotCreateShortcuts[] = L"do-not-create-shortcuts"; | 35 const char kDoNotCreateShortcuts[] = "do-not-create-shortcuts"; |
| 36 | 36 |
| 37 // Prevent installer from launching Chrome after a successful first install. | 37 // Prevent installer from launching Chrome after a successful first install. |
| 38 const wchar_t kDoNotLaunchChrome[] = L"do-not-launch-chrome"; | 38 const char kDoNotLaunchChrome[] = "do-not-launch-chrome"; |
| 39 | 39 |
| 40 // Prevents installer from writing the Google Update key that causes Google | 40 // Prevents installer from writing the Google Update key that causes Google |
| 41 // Update to launch Chrome after a first install. | 41 // Update to launch Chrome after a first install. |
| 42 const wchar_t kDoNotRegisterForUpdateLaunch[] = | 42 const char kDoNotRegisterForUpdateLaunch[] = |
| 43 L"do-not-register-for-update-launch"; | 43 "do-not-register-for-update-launch"; |
| 44 | 44 |
| 45 // By default we remove all shared (between users) files, registry entries etc | 45 // By default we remove all shared (between users) files, registry entries etc |
| 46 // during uninstall. If this option is specified together with kUninstall option | 46 // during uninstall. If this option is specified together with kUninstall option |
| 47 // we do not clean up shared entries otherwise this option is ignored. | 47 // we do not clean up shared entries otherwise this option is ignored. |
| 48 const wchar_t kDoNotRemoveSharedItems[] = L"do-not-remove-shared-items"; | 48 const char kDoNotRemoveSharedItems[] = "do-not-remove-shared-items"; |
| 49 | 49 |
| 50 // Enable logging at the error level. This is the default behavior. | 50 // Enable logging at the error level. This is the default behavior. |
| 51 const wchar_t kEnableLogging[] = L"enable-logging"; | 51 const char kEnableLogging[] = "enable-logging"; |
| 52 | 52 |
| 53 // If present, setup will uninstall chrome without asking for any | 53 // If present, setup will uninstall chrome without asking for any |
| 54 // confirmation from user. | 54 // confirmation from user. |
| 55 const wchar_t kForceUninstall[] = L"force-uninstall"; | 55 const char kForceUninstall[] = "force-uninstall"; |
| 56 | 56 |
| 57 // Specify the file path of Chrome archive for install. | 57 // Specify the file path of Chrome archive for install. |
| 58 const char kInstallArchive[] = "install-archive"; | 58 const char kInstallArchive[] = "install-archive"; |
| 59 | 59 |
| 60 // Specify the file path of Chrome master preference file. | 60 // Specify the file path of Chrome master preference file. |
| 61 const char kInstallerData[] = "installerdata"; | 61 const char kInstallerData[] = "installerdata"; |
| 62 | 62 |
| 63 // If present, specify file path to write logging info. | 63 // If present, specify file path to write logging info. |
| 64 const wchar_t kLogFile[] = L"log-file"; | 64 const char kLogFile[] = "log-file"; |
| 65 | 65 |
| 66 // Register Chrome as default browser on the system. Usually this will require | 66 // Register Chrome as default browser on the system. Usually this will require |
| 67 // that setup is running as admin. If running as admin we try to register | 67 // that setup is running as admin. If running as admin we try to register |
| 68 // as default browser at system level, if running as non-admin we try to | 68 // as default browser at system level, if running as non-admin we try to |
| 69 // register as default browser only for the current user. | 69 // register as default browser only for the current user. |
| 70 const wchar_t kMakeChromeDefault[] = L"make-chrome-default"; | 70 const char kMakeChromeDefault[] = "make-chrome-default"; |
| 71 | 71 |
| 72 // Tells installer to expect to be run as a subsidiary to an MSI. | 72 // Tells installer to expect to be run as a subsidiary to an MSI. |
| 73 const wchar_t kMsi[] = L"msi"; | 73 const char kMsi[] = "msi"; |
| 74 | 74 |
| 75 // Tells installer to install multiple products specified on the command line. | 75 // Tells installer to install multiple products specified on the command line. |
| 76 // (e.g. Chrome Frame, CEEE, Chrome) | 76 // (e.g. Chrome Frame, CEEE, Chrome) |
| 77 const wchar_t kMultiInstall[] = L"multi-install"; | 77 const char kMultiInstall[] = "multi-install"; |
| 78 | 78 |
| 79 // Useful only when used with --update-setup-exe, otherwise ignored. It | 79 // Useful only when used with --update-setup-exe, otherwise ignored. It |
| 80 // specifies the full path where updated setup.exe will be stored. | 80 // specifies the full path where updated setup.exe will be stored. |
| 81 const char kNewSetupExe[] = "new-setup-exe"; | 81 const char kNewSetupExe[] = "new-setup-exe"; |
| 82 | 82 |
| 83 // Register Chrome as a valid browser on the current sytem. This option | 83 // Register Chrome as a valid browser on the current sytem. This option |
| 84 // requires that setup.exe is running as admin. If this option is specified, | 84 // requires that setup.exe is running as admin. If this option is specified, |
| 85 // options kInstallArchive and kUninstall are ignored. | 85 // options kInstallArchive and kUninstall are ignored. |
| 86 const char kRegisterChromeBrowser[] = "register-chrome-browser"; | 86 const char kRegisterChromeBrowser[] = "register-chrome-browser"; |
| 87 | 87 |
| 88 const char kRegisterChromeBrowserSuffix[] = | 88 const char kRegisterChromeBrowserSuffix[] = |
| 89 "register-chrome-browser-suffix"; | 89 "register-chrome-browser-suffix"; |
| 90 | 90 |
| 91 // Renames chrome.exe to old_chrome.exe and renames new_chrome.exe to chrome.exe | 91 // Renames chrome.exe to old_chrome.exe and renames new_chrome.exe to chrome.exe |
| 92 // to support in-use updates. Also deletes opv key. | 92 // to support in-use updates. Also deletes opv key. |
| 93 const wchar_t kRenameChromeExe[] = L"rename-chrome-exe"; | 93 const char kRenameChromeExe[] = "rename-chrome-exe"; |
| 94 | 94 |
| 95 // Removes Chrome registration from current machine. Requires admin rights. | 95 // Removes Chrome registration from current machine. Requires admin rights. |
| 96 const wchar_t kRemoveChromeRegistration[] = L"remove-chrome-registration"; | 96 const char kRemoveChromeRegistration[] = "remove-chrome-registration"; |
| 97 | 97 |
| 98 // When we try to relaunch setup.exe as admin on Vista, we append this command | 98 // When we try to relaunch setup.exe as admin on Vista, we append this command |
| 99 // line flag so that we try the launch only once. | 99 // line flag so that we try the launch only once. |
| 100 const wchar_t kRunAsAdmin[] = L"run-as-admin"; | 100 const char kRunAsAdmin[] = "run-as-admin"; |
| 101 | 101 |
| 102 // Install Chrome to system wise location. The default is per user install. | 102 // Install Chrome to system wise location. The default is per user install. |
| 103 const wchar_t kSystemLevel[] = L"system-level"; | 103 const char kSystemLevel[] = "system-level"; |
| 104 | 104 |
| 105 // If present, setup will uninstall chrome. | 105 // If present, setup will uninstall chrome. |
| 106 const wchar_t kUninstall[] = L"uninstall"; | 106 const char kUninstall[] = "uninstall"; |
| 107 | 107 |
| 108 // Also see --new-setup-exe. This command line option specifies a diff patch | 108 // Also see --new-setup-exe. This command line option specifies a diff patch |
| 109 // that setup.exe will apply to itself and store the resulting binary in the | 109 // that setup.exe will apply to itself and store the resulting binary in the |
| 110 // path given by --new-setup-exe. | 110 // path given by --new-setup-exe. |
| 111 const char kUpdateSetupExe[] = "update-setup-exe"; | 111 const char kUpdateSetupExe[] = "update-setup-exe"; |
| 112 | 112 |
| 113 // Enable verbose logging (info level). | 113 // Enable verbose logging (info level). |
| 114 const wchar_t kVerboseLogging[] = L"verbose-logging"; | 114 const char kVerboseLogging[] = "verbose-logging"; |
| 115 | 115 |
| 116 // Show the embedded EULA dialog. | 116 // Show the embedded EULA dialog. |
| 117 const char kShowEula[] = "show-eula"; | 117 const char kShowEula[] = "show-eula"; |
| 118 | 118 |
| 119 // Use the alternate desktop shortcut name. | 119 // Use the alternate desktop shortcut name. |
| 120 const wchar_t kAltDesktopShortcut[] = L"alt-desktop-shortcut"; | 120 const char kAltDesktopShortcut[] = "alt-desktop-shortcut"; |
| 121 | 121 |
| 122 // Perform the inactive user toast experiment. | 122 // Perform the inactive user toast experiment. |
| 123 const char kInactiveUserToast[] = "inactive-user-toast"; | 123 const char kInactiveUserToast[] = "inactive-user-toast"; |
| 124 | 124 |
| 125 // User toast experiment switch from system context to user context. | 125 // User toast experiment switch from system context to user context. |
| 126 const wchar_t kSystemLevelToast[] = L"system-level-toast"; | 126 const char kSystemLevelToast[] = "system-level-toast"; |
| 127 | 127 |
| 128 // A handle value of the key to write the results of the toast experiment | 128 // A handle value of the key to write the results of the toast experiment |
| 129 // to. See DuplicateGoogleUpdateSystemClientKey for details. | 129 // to. See DuplicateGoogleUpdateSystemClientKey for details. |
| 130 const wchar_t kToastResultsKey[] = L"toast-results-key"; | 130 const char kToastResultsKey[] = "toast-results-key"; |
| 131 | 131 |
| 132 } // namespace switches | 132 } // namespace switches |
| 133 | 133 |
| 134 const wchar_t kChromeDll[] = L"chrome.dll"; | 134 const wchar_t kChromeDll[] = L"chrome.dll"; |
| 135 const wchar_t kChromeExe[] = L"chrome.exe"; | 135 const wchar_t kChromeExe[] = L"chrome.exe"; |
| 136 const wchar_t kChromeFrameDll[] = L"npchrome_frame.dll"; | 136 const wchar_t kChromeFrameDll[] = L"npchrome_frame.dll"; |
| 137 const wchar_t kChromeFrameHelperExe[] = L"chrome_frame_helper.exe"; | 137 const wchar_t kChromeFrameHelperExe[] = L"chrome_frame_helper.exe"; |
| 138 const wchar_t kChromeFrameHelperWndClass[] = L"ChromeFrameHelperWindowClass"; | 138 const wchar_t kChromeFrameHelperWndClass[] = L"ChromeFrameHelperWindowClass"; |
| 139 const wchar_t kChromeNaCl64Dll[] = L"nacl64.dll"; | 139 const wchar_t kChromeNaCl64Dll[] = L"nacl64.dll"; |
| 140 const wchar_t kChromeNewExe[] = L"new_chrome.exe"; | 140 const wchar_t kChromeNewExe[] = L"new_chrome.exe"; |
| 141 const wchar_t kChromeOldExe[] = L"old_chrome.exe"; | 141 const wchar_t kChromeOldExe[] = L"old_chrome.exe"; |
| 142 const wchar_t kGoogleChromeInstallSubDir1[] = L"Google"; | 142 const wchar_t kGoogleChromeInstallSubDir1[] = L"Google"; |
| 143 const wchar_t kGoogleChromeInstallSubDir2[] = L"Chrome"; | 143 const wchar_t kGoogleChromeInstallSubDir2[] = L"Chrome"; |
| 144 const wchar_t kInstallBinaryDir[] = L"Application"; | 144 const wchar_t kInstallBinaryDir[] = L"Application"; |
| 145 const wchar_t kInstallerDir[] = L"Installer"; | 145 const wchar_t kInstallerDir[] = L"Installer"; |
| 146 const wchar_t kInstallUserDataDir[] = L"User Data"; | 146 const wchar_t kInstallUserDataDir[] = L"User Data"; |
| 147 const wchar_t kNaClExe[] = L"nacl64.exe"; | 147 const wchar_t kNaClExe[] = L"nacl64.exe"; |
| 148 const wchar_t kSetupExe[] = L"setup.exe"; | 148 const wchar_t kSetupExe[] = L"setup.exe"; |
| 149 const wchar_t kSxSSuffix[] = L" SxS"; | 149 const wchar_t kSxSSuffix[] = L" SxS"; |
| 150 const wchar_t kUninstallStringField[] = L"UninstallString"; | 150 const wchar_t kUninstallStringField[] = L"UninstallString"; |
| 151 const wchar_t kUninstallArgumentsField[] = L"UninstallArguments"; | 151 const wchar_t kUninstallArgumentsField[] = L"UninstallArguments"; |
| 152 const wchar_t kUninstallDisplayNameField[] = L"DisplayName"; | 152 const wchar_t kUninstallDisplayNameField[] = L"DisplayName"; |
| 153 const char kUninstallMetricsName[] = "uninstall_metrics"; | 153 const char kUninstallMetricsName[] = "uninstall_metrics"; |
| 154 const wchar_t kUninstallInstallationDate[] = L"installation_date"; | 154 const wchar_t kUninstallInstallationDate[] = L"installation_date"; |
| 155 } // namespace installer_util | 155 } // namespace installer_util |
| OLD | NEW |