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 #include "chrome/installer/setup/install.h" | 5 #include "chrome/installer/setup/install.h" |
6 | 6 |
7 #include <windows.h> | 7 #include <windows.h> |
8 #include <shlobj.h> | 8 #include <shlobj.h> |
9 #include <time.h> | 9 #include <time.h> |
10 | 10 |
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
547 make_chrome_default || force_chrome_default_for_user); | 547 make_chrome_default || force_chrome_default_for_user); |
548 | 548 |
549 if (!installer_state.system_install()) { | 549 if (!installer_state.system_install()) { |
550 DCHECK_EQ(chrome_product->distribution(), | 550 DCHECK_EQ(chrome_product->distribution(), |
551 BrowserDistribution::GetDistribution()); | 551 BrowserDistribution::GetDistribution()); |
552 UpdateDefaultBrowserBeaconForPath( | 552 UpdateDefaultBrowserBeaconForPath( |
553 installer_state.target_path().Append(installer::kChromeExe)); | 553 installer_state.target_path().Append(installer::kChromeExe)); |
554 } | 554 } |
555 } | 555 } |
556 | 556 |
557 installer_state.UpdateStage(installer::REMOVING_OLD_VERSIONS); | 557 installer_state.UpdateStage(installer::REMOVING_OLD_VERSIONS); |
grt (UTC plus 2)
2016/02/24 20:06:16
move this to the new place where old versions are
fdoray
2016/02/25 18:26:47
Done.
| |
558 | |
559 installer_state.RemoveOldVersionDirectories( | |
560 new_version, | |
561 existing_version.get(), | |
562 install_temp_path); | |
563 } | 558 } |
564 | 559 |
565 return result; | 560 return result; |
566 } | 561 } |
567 | 562 |
568 void HandleOsUpgradeForBrowser(const installer::InstallerState& installer_state, | 563 void HandleOsUpgradeForBrowser(const installer::InstallerState& installer_state, |
569 const installer::Product& chrome, | 564 const installer::Product& chrome, |
570 const base::Version& installed_version) { | 565 const base::Version& installed_version) { |
571 DCHECK(chrome.is_chrome()); | 566 DCHECK(chrome.is_chrome()); |
572 | 567 |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
653 // Read master_preferences copied beside chrome.exe at install. | 648 // Read master_preferences copied beside chrome.exe at install. |
654 MasterPreferences prefs(installation_root.AppendASCII(kDefaultMasterPrefs)); | 649 MasterPreferences prefs(installation_root.AppendASCII(kDefaultMasterPrefs)); |
655 base::FilePath chrome_exe(installation_root.Append(kChromeExe)); | 650 base::FilePath chrome_exe(installation_root.Append(kChromeExe)); |
656 CreateOrUpdateShortcuts( | 651 CreateOrUpdateShortcuts( |
657 chrome_exe, chrome, prefs, CURRENT_USER, install_operation); | 652 chrome_exe, chrome, prefs, CURRENT_USER, install_operation); |
658 | 653 |
659 UpdateDefaultBrowserBeaconForPath(chrome_exe); | 654 UpdateDefaultBrowserBeaconForPath(chrome_exe); |
660 } | 655 } |
661 | 656 |
662 } // namespace installer | 657 } // namespace installer |
OLD | NEW |