summaryrefslogtreecommitdiffstats
path: root/chrome/installer/util/install_util.cc
Commit message (Collapse)AuthorAgeFilesLines
* Change base/file_utils.h includes to base/files/file_utils.h in chrome/, part 2.thestig2014-08-231-1/+1
| | | | | | Review URL: https://codereview.chromium.org/497083004 Cr-Commit-Position: refs/heads/master@{#291609}
* Omaha configuration parameters now use Wow6432Node (32-bit registry) on ↵wfh@chromium.org2014-05-281-12/+15
| | | | | | | | | | | | | | | 64-bit installs. GCAPI configuration parameters also use these same accesses since they read/write the same data. Also, force installation of Win64 into C:\Program Files (x86) until the code is added to support moving the files to the right place during upgrade and downgrade. Uninstall information will remain stored in the 32-bit registry (even on 64-bit) until the installation location is changed. This fixes system installs on Win64. BUG=338706 R=grt@chromium.org Review URL: https://codereview.chromium.org/300593002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@273108 0039d316-1c4b-4281-b951-d872f2087c98
* Add a flag to all of the registry related work items to specify whether to ↵wfh@chromium.org2014-05-231-16/+49
| | | | | | | | | | | | | | | | | | | operate on the 64-bit or 32-bit hive on a WOW64 system. Make DeleteRegKeyWorkItem call down into RegKey so WOW64 support works for delete work items. All calls changed to use the Wow64_Default (0) parameter, so the behavior is identical. This is prep for adding 64-bit support to the installer. BUG=348626,338706 R=grt@chromium.org, grt TBR=sky TEST=installer_util_unittests Review URL: https://codereview.chromium.org/282363003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@272539 0039d316-1c4b-4281-b951-d872f2087c98
* Remove stray platform_file.h from chrome and componentsrvargas@chromium.org2014-05-131-1/+0
| | | | | | | | BUG=322664 Review URL: https://codereview.chromium.org/273153003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@270166 0039d316-1c4b-4281-b951-d872f2087c98
* Fix the EULA sentinel file path determination.msw@chromium.org2014-04-151-8/+4
| | | | | | | | | | | | | | | | | | Add InstallUtil::GetEULASentinelFilePath as a helper. Use PathService to get the correct value of DIR_USER_DATA. (may be overridden by a policy, env var, or commandline) Nix GetSentinelFilePath, it just used the default dir. (similar to r260242's fix for the First Run sentinel) TODO(followup): Fix installer::GetChromeUserDataPath. BUG=354634 TEST=EULA sentinels respect command-line, env-var, and policy user-data-dir overrides. R=gab@chromium.org Review URL: https://codereview.chromium.org/237533004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@264030 0039d316-1c4b-4281-b951-d872f2087c98
* Remove stale code to delete the metro user data dir. It never shipped.grt@chromium.org2014-04-031-4/+3
| | | | | | | | | | | This more or less reverts r149968. BUG=none TBR=sky@chromium.org Review URL: https://codereview.chromium.org/218683013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@261457 0039d316-1c4b-4281-b951-d872f2087c98
* Fix the new First Run sentinel file path determination.msw@chromium.org2014-03-281-4/+15
| | | | | | | | | | | | | | | | | | | | | | | | Add first_run/InstallHelper GetFirstRunSentinelFilePath helpers. Use PathService to get the correct value of DIR_USER_DATA. (may be overridden by a policy, env var, or commandline) (InstallUtil::GetSentinelFilePath just uses the default dir) Make the IsFirstRunSentinelPresent helper platform-specific. (simplifies its predecessor's Win-specific legacy abstractions) Some related refactoring, cleanup, and test updates. TODO(msw): Fix InstallUtil::GetSentinelFilePath. TODO(msw): Fix/Nix installer::GetChromeUserDataPaths. TODO(msw): Further consolidate related/duplicated code. BUG=354634,341049 TEST=Chrome install and first run work as intended; respect user-data-dir commandline, env var, and policy overrides. R=grt@chromium.org TBR=gab@chromium.org Review URL: https://codereview.chromium.org/208393020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@260242 0039d316-1c4b-4281-b951-d872f2087c98
* Move UTF16ToASCII, remove WideToASCII.brettw@chromium.org2014-03-141-2/+3
| | | | | | | | | | | | | | | | This removes WideToASCII and changes all callers to use UTF16ToASCII instead. Moves UTF16ToASCII from base/strings/string_util.h to base/strings/utf_string_conversions.h and into the base namespace. Convert a few related string_util functions to take a StringPiece16 instead of a string16. Remove IsStringASCII(std::wstring) which was unused. Updates callers' includes and namespace usage accordingly. TBR=sky Review URL: https://codereview.chromium.org/176843022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@257200 0039d316-1c4b-4281-b951-d872f2087c98
* Add a histogram to track Chrome's UpdatePolicy in the field.gab@chromium.org2014-03-031-2/+1
| | | | | | | | | | | | | BUG=346494 TEST=Run dev chrome and confirm (after 45s) that chrome://histograms shows: GoogleUpdate.UpdatePolicyIsOverridden => 0 (false) GoogleUpdate.EffectivePolicy => 1 (AUTOMATIC_UPDATES) R=asvitkine@chromium.org, grt@chromium.org, isherman@chromium.org Review URL: https://codereview.chromium.org/178473004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254595 0039d316-1c4b-4281-b951-d872f2087c98
* Move TrimWhitespace to the base namespace.brettw@chromium.org2014-03-031-1/+1
| | | | | | | | R=viettrungluu@chromium.org, viettrungluu Review URL: https://codereview.chromium.org/183853011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254521 0039d316-1c4b-4281-b951-d872f2087c98
* Always drop the First Run sentinel in the User Data directory.gab@chromium.org2014-02-261-34/+9
| | | | | | | | | | | | | | | | | | | | | | | Also: 1) Don't RemoveSentinel on uninstall (also required to address issue 341049). 2) Copy the legacy First Run sentinel to the new location on user-level installs. 3) Reorder chrome_browser_main to put early return paths as early as possible + make sure first_run::CreateSentinelIfNeeded() comes AFTER any early return. 4) Have all sentinel obtention code go through InstallUtil::GetSentinelFilePathForDist() (renamed from InstallUtil::GetSentinelFilePath() to highlight all affected paths -- which were already all system-level only paths, except for the self-destruct path which is no longer required and was removed along with --cancel-first-run). 5) Introduce installer::switches::kTriggerActiveSetup to allow Chrome to tell setup.exe that it should trigger active setup if the system-level Chrome taking over will not undergo first run (rather than relying on setup to read the first run sentinel itself). BUG=341049 TEST= A: 1) Install+run old user-level chrome (goes through first run) 2) Close old chrome 3) Install new chrome and run it (ensure First Run beacon is migrated and no first run flow occurs) 4) Uninstall new chrome and make sure the Application folder is deleted despite the lingering First Run sentinel which is no longer actively removed on uninstall. B: Self-destruct flow still works as intended (uninstalls user-level and launches system-level in first run or not, just like user-level should have launched) Review URL: https://codereview.chromium.org/166853003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253630 0039d316-1c4b-4281-b951-d872f2087c98
* Installer: remove uses of PlatformFilervargas@chromium.org2014-02-251-19/+16
| | | | | | | | | BUG=322664 R=grt@chromium.org Review URL: https://codereview.chromium.org/173853004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@253168 0039d316-1c4b-4281-b951-d872f2087c98
* Convert base::file_util to use File instead of PlatformFile.rvargas@chromium.org2014-01-071-0/+1
| | | | | | | | | | | BUG=322664 R=brettw@chromium.org TBR=darin@chromium.org Review URL: https://codereview.chromium.org/101143006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@243235 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Update all users of base::Version to explicitly specify the ↵avi@chromium.org2014-01-031-6/+6
| | | | | | | | | | | | | | namespace, and clean up the header." This is a speculative revert of r242414. BUG=330681 TEST=as in bug TBR=ben@chromium.org Review URL: https://codereview.chromium.org/109673004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242889 0039d316-1c4b-4281-b951-d872f2087c98
* Update all users of base::Version to explicitly specify the namespace, and ↵avi@chromium.org2013-12-231-6/+6
| | | | | | | | | | | | clean up the header. BUG=none TEST=no change TBR=ben@chromium.org Review URL: https://codereview.chromium.org/100543005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242414 0039d316-1c4b-4281-b951-d872f2087c98
* Add base:: to string16s in chrome/.dbeam@chromium.org2013-12-201-27/+28
| | | | | | | | | TBR=sky@chromium.org BUG=329295 Review URL: https://codereview.chromium.org/94013004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@242048 0039d316-1c4b-4281-b951-d872f2087c98
* Uninstall multi-install Chrome Frame when updated.grt@chromium.org2013-12-041-0/+4
| | | | | | | | | | | | | | If multi-install Chrome Frame is present when a multi-install install or update is processed, CF is uninstalled prior to ordinary processing. The binaries will be removed if they are not in use. Otherwise, they will stick around until the next update for which they are not in use. BUG=316496 R=robertshield@chromium.org Review URL: https://codereview.chromium.org/96193003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@238588 0039d316-1c4b-4281-b951-d872f2087c98
* Uninstall chrome binaries that are no longer in use.grt@chromium.org2013-10-081-0/+1
| | | | | | | | | | | | | | | | | | | | | | | When Chrome Frame is migrated from multi-install to single-install, it may leave behind the mulit-install binaries with no products. This change causes the binaries to uninstall themselves on a subsequent update if they are no longer in use. This is accomplished as follows: InstallProducts will abort early and return UNUSED_BINARIES if no products are installed. If the binaries are still in use (e.g., npchrome_frame.dll is loaded in a running IE), the overall update will fail with this InstallerError. If, on the other hand, the binaries are not in use, UninstallProducts will run and remove them. In this case, the overall installer result will indicate success to Google Update (InstallerResult == 0) with InstallerError set to UNUSED_BINARIES_UNINSTALLED. BUG=265952 TEST=install multi-install CF of version N-2, update it to N-1 and note that CF is now SxS but binaries still exist, then update binaries to version N and note that binaries are gone Review URL: https://codereview.chromium.org/25859007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@227491 0039d316-1c4b-4281-b951-d872f2087c98
* Address renaming nits from previous review.zturner@chromium.org2013-09-141-2/+3
| | | | | | | | | | | | Original review: https://codereview.chromium.org/23258005 Can't TBR because I don't have full committer yet. BUG=273248 Review URL: https://chromiumcodereview.appspot.com/24144002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@223196 0039d316-1c4b-4281-b951-d872f2087c98
* Give SxS distribution its own registration GUIDs.zturner@chromium.org2013-09-131-4/+20
| | | | | | | | | | | | | See the linked bug for more information about this change. BUG=273248 gab: chrome/installer/* ananta, cpu: win8/ Review URL: https://chromiumcodereview.appspot.com/23258005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@222987 0039d316-1c4b-4281-b951-d872f2087c98
* Refactor of BrowserDistribution.calamity@chromium.org2013-08-141-4/+4
| | | | | | | | | | | | | | | | | | | This is a precursor to https://codereview.chromium.org/13864015/. * Added GetStartMenuShortcutSubfolder, which returns the Start Menu subfolder path for a given subfolder. * GetShortcutName and GetIconIndex now return data specific to a type of shortcut (browser, alternate name of browser, or app launcher). * GetDisplayName is now used rather than GetAppShortcutName where a localized name is needed (e.g., in logs and the registry). BUG=233434,238895,161985 Review URL: https://chromiumcodereview.appspot.com/15255004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@217469 0039d316-1c4b-4281-b951-d872f2087c98
* Update include paths in chrome/installer/ for base/process changes.rsesek@chromium.org2013-07-231-1/+1
| | | | | | | | | BUG=242290 R=robertshield@chromium.org Review URL: https://codereview.chromium.org/19741008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@213107 0039d316-1c4b-4281-b951-d872f2087c98
* Move PathExists to base namespace.brettw@chromium.org2013-07-111-2/+2
| | | | | | | | | BUG= TBR=jam@chromium.org Review URL: https://codereview.chromium.org/18286004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@211147 0039d316-1c4b-4281-b951-d872f2087c98
* Use a direct include of strings headers in chrome/installer/, part 2.avi@chromium.org2013-06-111-1/+1
| | | | | | | | | | BUG=247723 TEST=none TBR=ben@chromium.org Review URL: https://chromiumcodereview.appspot.com/16421004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@205431 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 184352brettw@chromium.org2013-02-241-2/+2
| | | | | | | | | | | | | | | | | > Add utf_string_conversions to base namespace. > > This adds "using"s for all functions so those can be fixed in a separate pass. > > This converts the "Wide" versions of the functions in the Chrome directory as a first pass on the changeover. > > BUG= > > Review URL: https://codereview.chromium.org/12314090 TBR=brettw@chromium.org Review URL: https://codereview.chromium.org/12315071 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@184355 0039d316-1c4b-4281-b951-d872f2087c98
* Add utf_string_conversions to base namespace.brettw@chromium.org2013-02-241-2/+2
| | | | | | | | | | | | This adds "using"s for all functions so those can be fixed in a separate pass. This converts the "Wide" versions of the functions in the Chrome directory as a first pass on the changeover. BUG= Review URL: https://codereview.chromium.org/12314090 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@184352 0039d316-1c4b-4281-b951-d872f2087c98
* Move FilePath->base::FilePathbrettw@chromium.org2013-02-111-16/+18
| | | | | | Review URL: https://codereview.chromium.org/12213104 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@181663 0039d316-1c4b-4281-b951-d872f2087c98
* Refactoring: Splitting AddGenericQuickEnableWorkItems().huangs@chromium.org2013-02-041-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a refactoring task in preparation for adding "RunAsUser" flag in app commands [TODO: Get BUG id]. In install_util.cc, AddGenericQuickEnableWorkItems() was a large routine that contains common code for (A) AddQuickEnableChromeFrameWorkItems() for "quick-enable-cf" (B) AddQuickEnableApplicationLauncherWorkItems() for "quick-enable-application-host" It was assumed that (A) and (B) set the same flags ("SendsPoints" and "WebAccessible"). This assumption will no longer hold once we add "RunAsUser" (for (B) only). However, the flag-setting part is buried deep inside AddGenericQuickEnableWorkItems(). The refactoring task splits the subroutine into smaller parts, and produce some duplicate glue code with acceptibly small repetition. AddGenericQuickEnableWorkItems() is split into the following (+ glue code): (1) WillProductBePresentAfterSetup() => moved to install_util.cc (2) GetGenericQuickEnableCommand() We also made (1) absorb existing code in (A). In addition, (3) GetRegCommandKey() is extracted to eliminate duplicate code to access App Command registry entries. Glue codes are found in the callers (A) and (B). Moreover, code that is used in (A) only are not repeated in (B). BUG=160293 Review URL: https://chromiumcodereview.appspot.com/12114016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@180481 0039d316-1c4b-4281-b951-d872f2087c98
* Chromium didn't have an Active Setup GUID -- fix that.gab@chromium.org2013-01-301-1/+1
| | | | | | | | | | | | | This would have caused the installer to write straight into Software\Microsoft\Active Setup\Installed Components if Chromium was installed at system-level... Separated AppGuid from ActiveSetupGuid as the AppGuid is really a Google Update construct only. R=robertshield@chromium.org Review URL: https://chromiumcodereview.appspot.com/12041025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@179715 0039d316-1c4b-4281-b951-d872f2087c98
* [Fixit-Dec-2012] Auto-launch system-level Chrome post user-level Chrome ↵gab@chromium.org2013-01-051-1/+16
| | | | | | | | | | | | | | | | | | self-destruction. Also changed self-destruct to launch setup.exe using ShellExecute instead of base::LaunchProcess to allow us to specify SEE_MASK_FLAG_LOG_USAGE to flip to the desktop as documented in "DevelopinganewexperienceDesktopBrowser". This only seems to work when ShellExecute is called from an immersive process and thus setup.exe must be launched with this flag (if it's not and setup later tries to ShellExecute the system-level Chrome with that flag, the desktop flip doesn't occur...). Also fixed InstallUtil::GetSentinelFilePath() which used to get DIR_EXE from the PathService to determine whether it was a user-level install and if so return DIR_EXE as the sentinel file path; this was wrong when called from setup.exe as DIR_EXE is not Application\ in that case, it's Application\<version>\Installer...! Thankfully this method was not used to set the sentinel (so that we don't have to keep checking for sentinel files in the wrong places); we could up until this CL however get constant false negatives when looking for sentinels with this method. This CL depends on https://codereview.chromium.org/11636031/. BUG=165048 TEST=Self-destruct with/without First Run having occured (prior to the system-level install) for the user-level Chrome; the self-destruct should occur and launch System-level Chrome with/without the First Run flow (i.e. with First Run only if the self-destructing Chrome itself hadn't undergone First Run already). On Win8, the above scenarios should work whether the user-level Chrome prefers Metro or not (if it does prefer Metro the immersive launch should flip back to the desktop for the self-destruct -- the self-destruct message dialog is still suppressed in that case however). Review URL: https://chromiumcodereview.appspot.com/11685006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175249 0039d316-1c4b-4281-b951-d872f2087c98
* Windows: Remove desktop profile shortcuts (and any others pointing to the ↵asvitkine@chromium.org2013-01-041-2/+6
| | | | | | | | | | | | | exe) on uninstall. This is a re-land of https://codereview.chromium.org/11693010/, which failed on the tree on XP bots. The issue was that ProgramCompare::Evaluate() was parsing its value parameter is a command-line, which meant it was truncating it at the first space. This updated CL adds an EvaluatePath() function that takes a FilePath and doesn't try to parse it as a command-line. BUG=146636 TEST=Uninstalling Chrome removes any present profile shortcuts on the desktop. Review URL: https://chromiumcodereview.appspot.com/11743022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175104 0039d316-1c4b-4281-b951-d872f2087c98
* Launch system-level Active Setup immediately following self-destruction of a ↵gab@chromium.org2012-11-211-10/+6
| | | | | | | | | | | | | | | user-level Chrome. 1st attempt at https://codereview.chromium.org/11359219/ was reverted (see comments post commit on that CL). TBR=thakis BUG=158524 TEST=Install user-level Chrome on user A, install system-level Chrome on user B (while A is still logged in), go back to user A and run Chrome, user-level Chrome self-destructs and new shortcuts are installed pointing to system-level Chrome. Try with: user A's chrome never ran, user A's Chrome ran and is set to prefer desktop chrome, user A's Chrome ran and is set to prefer Metro mode. Review URL: https://chromiumcodereview.appspot.com/11420045 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@169079 0039d316-1c4b-4281-b951-d872f2087c98
* Introduce --install-dev-chrome switch for setup.exe to install ↵gab@chromium.org2012-11-061-19/+0
| | | | | | | | | | | | | (register+shortcuts) a local build of chrome.exe Usage: setup.exe --install-dev-chrome=C:\full\path\to\chrome.exe BUG=155217 Review URL: https://chromiumcodereview.appspot.com/11362092 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@166297 0039d316-1c4b-4281-b951-d872f2087c98
* No longer install all-users shortcuts on system-level installs; instead ↵gab@chromium.org2012-10-301-3/+41
| | | | | | | | | | | | | | | install per-user shortcuts through Active Setup. Design doc: https://docs.google.com/a/chromium.org/document/d/1FjFbmKVj0BIP7xBXMs4lLgQcrc--Jl5jiMiwdDxLeOs/edit BUG=148539 TEST=Shortcuts work as described in the design doc :)! installer_util_unittests.exe --gtest_filter=ShellUtilShortcut* setup_unittests.exe --gtest_filter=InstallShortcutTest* Review URL: https://chromiumcodereview.appspot.com/11229010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@164849 0039d316-1c4b-4281-b951-d872f2087c98
* Delegate installation of multi-install products to a pre-existing higher ↵grt@chromium.org2012-10-251-0/+2
| | | | | | | | | | | | | version of the binaries if there is one. Updates are not modified. In so doing, the archive is now extracted into a unique directory so that the two setup.exe invocations don't unpack into the same dir. BUG=157410 TEST=install multi-install GCF version N (possibly not including this change) then try to install Chrome version N-M (including this change). Review URL: https://chromiumcodereview.appspot.com/11272003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@164040 0039d316-1c4b-4281-b951-d872f2087c98
* Allow NULL in addition to the empty string to address the default value in a ↵grt@chromium.org2012-09-261-3/+2
| | | | | | | | | | | registry key. This is the norm for the Win32 API. base::win::RegKey need not disallow a NULL name in DeleteValue. BUG=none TEST=none Review URL: https://chromiumcodereview.appspot.com/10987033 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@158928 0039d316-1c4b-4281-b951-d872f2087c98
* Enable EULA dialog to be shown from metro Chrome.robertshield@chromium.org2012-09-261-0/+24
| | | | | | | | | | BUG=131033 TEST=Run Chrome in Metro mode while the EULA dialog still needs to be accepted. Get kicked back to the desktop to accept the dialog. On accept, get kicked back into metro mode. Review URL: https://chromiumcodereview.appspot.com/10837222 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@158797 0039d316-1c4b-4281-b951-d872f2087c98
* Remove two deprecated methods from base::Versionisherman@chromium.org2012-07-111-15/+14
| | | | | | | | | | BUG=none TEST=none TBR=sky@chromium.org Review URL: https://chromiumcodereview.appspot.com/10683005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@146157 0039d316-1c4b-4281-b951-d872f2087c98
* Abstract suffixing logic away from GetApplicationNamegab@chromium.org2012-06-171-5/+5
| | | | | | | | | BUG=124013, 125362, 133173 TEST=http://goo.gl/ZZ7gE Review URL: https://chromiumcodereview.appspot.com/10446111 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@142641 0039d316-1c4b-4281-b951-d872f2087c98
* Always suffix ChromeHTML entries on Windows for user-level installs.gab@chromium.org2012-06-171-13/+12
| | | | | | | | | | | | | This also adds the same suffixing to Chrome's appname for Default Programs registration (this suffix is not user-facing though as we don't suffix the actual string representing Chrome in the UI... obviously!) Design doc: https://docs.google.com/a/chromium.org/document/d/1qmcV3uYBh3JwvXhYkI7asg0nN7KfVMWVOzND4p0jQ3E/edit BUG=125362,124013,133173 TEST=http://goo.gl/ZZ7gE Review URL: https://chromiumcodereview.appspot.com/10451074 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@142634 0039d316-1c4b-4281-b951-d872f2087c98
* Move ProgramCompare from setup_util to install_util.gab@chromium.org2012-05-311-18/+88
| | | | | | | | | | | | | ...and switch to oh so ever beautiful string16s. BUG=None TEST=setup_util_unittests installer_util_unittests --gtest_filter=InstallUtilTest.ProgramCompare Review URL: https://chromiumcodereview.appspot.com/10446095 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@139837 0039d316-1c4b-4281-b951-d872f2087c98
* 1) Generate VisualElementsManifest.xml at install time from a pre-defined ↵gab@chromium.org2012-05-071-0/+2
| | | | | | | | | | | | | | | | | | | | | | template. This allows us to put images in the version directory (i.e. a path that changes each istall; rather than needing the images beside chrome.exe). This also allows us to localize the Display Name of Google Chrome. This however does not fix bug #123376 (we have the same issue here). 2) Fixes create_installer_archive.py to not create empty directories for output directories specified in chrome.release for which the input is not present when packaging chrome.7z 3) Removes "Dictionaries\en-US.bdic: %(ChromeDir)s\Dictionaries" from chrome.release which has not been packaged since Chrome 17 (and maybe even before that). 4) (2+3) have the side-effect that there is no longer an empty Dictionaries/ directory created at install. BUG=123319,123376 TEST=Install Chrome on Win8 and watch VisualElementsManifest.xml land with the correct values. Overinstall Chrome on a Win8 install with VisualElementsManifest.xml from an installer that doesn't have VisualElements --> ensure VisualElementsManifest.xml is deleted and icons go back to default-style. Review URL: http://codereview.chromium.org/10160011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@135615 0039d316-1c4b-4281-b951-d872f2087c98
* Don't register or use the DelegateExecute verb handler if it isn't present.grt@chromium.org2012-04-251-0/+19
| | | | | | | | | BUG=124666,123994 TEST=install canary on a win8 box and note that the DelegateExecute verb handler isn't registered in HKCR and that registration for shell verbs don't refer to it. Review URL: http://codereview.chromium.org/10213010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@133995 0039d316-1c4b-4281-b951-d872f2087c98
* Cleanup: Remove calls to deprecated file_util::AppendToPath() in ↵thestig@chromium.org2012-03-091-19/+1
| | | | | | | | | | | chrome/installer. BUG=24672 TEST=install Chrome and make it the default browser. verify that filetype (double-click an .html file) and protocol registrations (enter http://www.google.com/ in the Run... dialog) still work. Review URL: http://codereview.chromium.org/9616046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125834 0039d316-1c4b-4281-b951-d872f2087c98
* Break two classes defined in json_value_serializer.cc, .h into separate files.bbudge@chromium.org2012-02-261-1/+0
| | | | | | | | | This will allow the use of JSONStringValueSerializer in the NaCl sandbox. BUG=none TEST=none Review URL: https://chromiumcodereview.appspot.com/9465030 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@123701 0039d316-1c4b-4281-b951-d872f2087c98
* Implement an AutoLaunch experiment for Chrome for certain brand codes. This ↵finnur@chromium.org2011-12-151-2/+5
| | | | | | | | | | is for Windows only. BUG=95971 TEST=This requires a special branded build to test (and master_preferences set to have auto_launch_chrome: true or specify mini_installer param --auto-launch-chrome), but after installing it you should see an item under the Wrench \ Options \ Basics that lets you configure Chrome to not auto-launch. If you instead, log out and log in again, Chrome should start with an infobar saying that it was auto-launched. The infobar should stay for a max of 5 launches and then not appear again. Pressing "Cut it out!" on the infobar should turn off this feature. If you just want to test the infobar, launch chrome with --auto-launch-at-startup. Also, uninstall and make sure Chrome is not auto-launched (a Windows error about Chrome not being found should not be shown). Review URL: http://codereview.chromium.org/8729009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@114621 0039d316-1c4b-4281-b951-d872f2087c98
* Add support for --critical-update-version to installer.grt@chromium.org2011-11-111-1/+1
| | | | | | | | | | | | | | | | The installer may now be given a --critical-update-version=W.X.Y.Z option on the command line. If this is present for an in-use update and the indicated version is newer than the in-use Chrome, a new "cpv" value is dropped in the registry alongside "opv" and "cmd" (the other state associated with an in-use update). Thanks to Finnur, Chrome will eventually notice that there's a pending critical update and do magical things to keep our users safe and secure. Go users! Other things I did while I was at it: - switched version string conversions from UTF8ToWide to ASCIIToWide since version numbers are always ASCII dotted numbers. - renamed the reg value from "CriticalUpdate" to "cpv" so it fits in nicely with the other cryptic values in the product's Clients key (a.k.a. Version key). BUG=103526,97665 TEST=Install version N, launch it with --check-for-update-interval=5, then install verison M>N with --critical-update-version=M. After a few seconds, Chrome should do something fantastic. Note that the alternate_version_generator can be used to create a newer versioned mini_installer from an existing one (just build it and run it). Review URL: http://codereview.chromium.org/8517012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@109620 0039d316-1c4b-4281-b951-d872f2087c98
* Change UpgradeDetectorImpl to use InstallUtil::IsPerUserInstall, which is ↵finnur@chromium.org2011-11-081-2/+4
| | | | | | | | | | | less flaky than looking for pv values in the registry. Also remove the restriction on checking only for user-level installs of Chrome (not necessary). BUG=103226 TEST=The upgrade notification on the wrench menu should work as before for both user-level and system-level. Review URL: http://codereview.chromium.org/8491011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@109013 0039d316-1c4b-4281-b951-d872f2087c98
* Fix default browser registration for simplified chinese installs.grt@chromium.org2011-11-021-6/+10
| | | | | | | | | | | | | http://crrev.com/13341 and http://crrev.com/13906, which fixed http://crbug.com/9697, switched from using chrome.exe as the canonical name of Chrome (for purposes of shell registration) to using the localized application name (e.g., "Chromium" or "Google Chrome"). This is problematic since there are differences between the various locales as to what the app name is. This change switches to using a non-localized version of the product name. The right thing to do would really be to switch back to using the executable name (as prescribed by MSDN), except for the case of Chromium builds, where "chromium.exe" could be used. Making that change now would mean potentially re-prompting users to make Chrome their default browser, which would be bad. BUG=92445 TEST=Verify that Google Chrome and Chromium builds can coexist, and that each can be made the default browser. Furthermore, ensure that, for user-level and system-level installs, all of the usual shell registration things work: the Start Menu's "Internet" link (icon and action), running "chrome.exe" (without path) from the Run... dialog, clicking a link in some other program, typeing a URL into the Run... dialog, "Set your default programs" control panel, "Set program access and computer defaults" control panel. Also, verify that if Chrome is installed using zn-CH locale and made the default, that switching to another locale (like en-US) doesn't cause Chrome to prompt to become the default browser. Review URL: http://codereview.chromium.org/8384038 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@108297 0039d316-1c4b-4281-b951-d872f2087c98
* base/win: small improvement to RegKey API.tfarina@chromium.org2011-10-181-1/+1
| | | | | | | | | | | | - Rename ValueExists() to HasValue(). - Rename ValueCount() to GetValueCount(). - Rename ReadName() to GetValueNameAt(). R=maruel@chromium.org,willchan@chromium.org Review URL: http://codereview.chromium.org/8337006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@106074 0039d316-1c4b-4281-b951-d872f2087c98