OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 <shlobj.h> | 5 #include <shlobj.h> |
6 #include <time.h> | 6 #include <time.h> |
7 | 7 |
8 #include "chrome/installer/setup/install.h" | 8 #include "chrome/installer/setup/install.h" |
9 | 9 |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
272 | 272 |
273 std::wstring arguments; | 273 std::wstring arguments; |
274 AppendUninstallCommandLineFlags(&arguments, system_install); | 274 AppendUninstallCommandLineFlags(&arguments, system_install); |
275 | 275 |
276 LOG(INFO) << "Creating/updating uninstall link at " | 276 LOG(INFO) << "Creating/updating uninstall link at " |
277 << uninstall_link.value(); | 277 << uninstall_link.value(); |
278 ret = ret && file_util::CreateShortcutLink(setup_exe.c_str(), | 278 ret = ret && file_util::CreateShortcutLink(setup_exe.c_str(), |
279 uninstall_link.value().c_str(), | 279 uninstall_link.value().c_str(), |
280 NULL, | 280 NULL, |
281 arguments.c_str(), | 281 arguments.c_str(), |
282 NULL, setup_exe.c_str(), 0); | 282 NULL, setup_exe.c_str(), 0, |
| 283 NULL); |
283 } | 284 } |
284 | 285 |
285 // Update Desktop and Quick Launch shortcuts. If --create-new-shortcuts | 286 // Update Desktop and Quick Launch shortcuts. If --create-new-shortcuts |
286 // is specified we want to create them, otherwise we update them only if | 287 // is specified we want to create them, otherwise we update them only if |
287 // they exist. | 288 // they exist. |
288 if (system_install) { | 289 if (system_install) { |
289 ret = ret && ShellUtil::CreateChromeDesktopShortcut(chrome_exe, | 290 ret = ret && ShellUtil::CreateChromeDesktopShortcut(chrome_exe, |
290 product_desc, ShellUtil::SYSTEM_LEVEL, alt_shortcut, | 291 product_desc, ShellUtil::SYSTEM_LEVEL, alt_shortcut, |
291 create_all_shortcut); | 292 create_all_shortcut); |
292 ret = ret && ShellUtil::CreateChromeQuickLaunchShortcut(chrome_exe, | 293 ret = ret && ShellUtil::CreateChromeQuickLaunchShortcut(chrome_exe, |
(...skipping 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
663 } | 664 } |
664 | 665 |
665 std::wstring latest_version_to_keep(new_version.GetString()); | 666 std::wstring latest_version_to_keep(new_version.GetString()); |
666 if (!current_version.empty()) | 667 if (!current_version.empty()) |
667 latest_version_to_keep.assign(current_version); | 668 latest_version_to_keep.assign(current_version); |
668 RemoveOldVersionDirs(install_path, latest_version_to_keep); | 669 RemoveOldVersionDirs(install_path, latest_version_to_keep); |
669 } | 670 } |
670 | 671 |
671 return result; | 672 return result; |
672 } | 673 } |
OLD | NEW |