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/setup_main.h" | 5 #include "chrome/installer/setup/setup_main.h" |
6 | 6 |
7 #include <windows.h> | 7 #include <windows.h> |
8 #include <msi.h> | 8 #include <msi.h> |
9 #include <shellapi.h> | 9 #include <shellapi.h> |
10 #include <shlobj.h> | 10 #include <shlobj.h> |
(...skipping 942 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
953 installer::InstallStatus status = installer::FIRST_INSTALL_SUCCESS; | 953 installer::InstallStatus status = installer::FIRST_INSTALL_SUCCESS; |
954 if (base::PathExists(chrome_exe)) { | 954 if (base::PathExists(chrome_exe)) { |
955 Product chrome(chrome_dist); | 955 Product chrome(chrome_dist); |
956 | 956 |
957 // Create the Start menu shortcut and pin it to the taskbar. | 957 // Create the Start menu shortcut and pin it to the taskbar. |
958 ShellUtil::ShortcutProperties shortcut_properties(ShellUtil::CURRENT_USER); | 958 ShellUtil::ShortcutProperties shortcut_properties(ShellUtil::CURRENT_USER); |
959 chrome.AddDefaultShortcutProperties(chrome_exe, &shortcut_properties); | 959 chrome.AddDefaultShortcutProperties(chrome_exe, &shortcut_properties); |
960 shortcut_properties.set_dual_mode(true); | 960 shortcut_properties.set_dual_mode(true); |
961 shortcut_properties.set_pin_to_taskbar(true); | 961 shortcut_properties.set_pin_to_taskbar(true); |
962 ShellUtil::CreateOrUpdateShortcut( | 962 ShellUtil::CreateOrUpdateShortcut( |
963 ShellUtil::SHORTCUT_LOCATION_START_MENU, chrome_dist, | 963 ShellUtil::SHORTCUT_LOCATION_START_MENU_CHROME_DIR, chrome_dist, |
964 shortcut_properties, ShellUtil::SHELL_SHORTCUT_CREATE_ALWAYS); | 964 shortcut_properties, ShellUtil::SHELL_SHORTCUT_CREATE_ALWAYS); |
965 | 965 |
966 // Register Chrome at user-level and make it default. | 966 // Register Chrome at user-level and make it default. |
967 scoped_ptr<WorkItemList> delegate_execute_list( | 967 scoped_ptr<WorkItemList> delegate_execute_list( |
968 WorkItem::CreateWorkItemList()); | 968 WorkItem::CreateWorkItemList()); |
969 installer::AddDelegateExecuteWorkItems( | 969 installer::AddDelegateExecuteWorkItems( |
970 installer_state, chrome_exe.DirName(), Version(), chrome, | 970 installer_state, chrome_exe.DirName(), Version(), chrome, |
971 delegate_execute_list.get()); | 971 delegate_execute_list.get()); |
972 delegate_execute_list->Do(); | 972 delegate_execute_list->Do(); |
973 if (ShellUtil::CanMakeChromeDefaultUnattended()) { | 973 if (ShellUtil::CanMakeChromeDefaultUnattended()) { |
(...skipping 859 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1833 // Call the newly updated setup.exe with kUncompressedArchive and | 1833 // Call the newly updated setup.exe with kUncompressedArchive and |
1834 // kMigrateChromeFrame to perform the migration. | 1834 // kMigrateChromeFrame to perform the migration. |
1835 LaunchChromeFrameMigrationProcess(*chrome_frame_state, cmd_line, | 1835 LaunchChromeFrameMigrationProcess(*chrome_frame_state, cmd_line, |
1836 installer_directory, system_install); | 1836 installer_directory, system_install); |
1837 } | 1837 } |
1838 | 1838 |
1839 VLOG(1) << "Installation complete, returning: " << return_code; | 1839 VLOG(1) << "Installation complete, returning: " << return_code; |
1840 | 1840 |
1841 return return_code; | 1841 return return_code; |
1842 } | 1842 } |
OLD | NEW |