Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(146)

Side by Side Diff: chrome/installer/setup/install.cc

Issue 57173002: Adds the concept of a 'safe mode' hotkey start (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/chrome_browser_main_win.cc ('k') | chrome/installer/util/browser_distribution.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 439 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 // IMPORTANT: Only the default (no arguments and default browserappid) browser 450 // IMPORTANT: Only the default (no arguments and default browserappid) browser
451 // shortcut in the Start menu (Start screen on Win8+) should be made dual 451 // shortcut in the Start menu (Start screen on Win8+) should be made dual
452 // mode. 452 // mode.
453 start_menu_properties.set_dual_mode(true); 453 start_menu_properties.set_dual_mode(true);
454 if (!do_not_create_taskbar_shortcut && 454 if (!do_not_create_taskbar_shortcut &&
455 (shortcut_operation == ShellUtil::SHELL_SHORTCUT_CREATE_ALWAYS || 455 (shortcut_operation == ShellUtil::SHELL_SHORTCUT_CREATE_ALWAYS ||
456 shortcut_operation == 456 shortcut_operation ==
457 ShellUtil::SHELL_SHORTCUT_CREATE_IF_NO_SYSTEM_LEVEL)) { 457 ShellUtil::SHELL_SHORTCUT_CREATE_IF_NO_SYSTEM_LEVEL)) {
458 start_menu_properties.set_pin_to_taskbar(true); 458 start_menu_properties.set_pin_to_taskbar(true);
459 } 459 }
460 // The 'launch in safe mode' hotkey should be set only for the start menu
461 // shortcut.
462 int hotkey = dist->GetSafeModeHotkey();
463 if (hotkey)
464 start_menu_properties.set_hotkey(hotkey);
460 ExecuteAndLogShortcutOperation(ShellUtil::SHORTCUT_LOCATION_START_MENU, 465 ExecuteAndLogShortcutOperation(ShellUtil::SHORTCUT_LOCATION_START_MENU,
461 dist, start_menu_properties, 466 dist, start_menu_properties,
462 shortcut_operation); 467 shortcut_operation);
463 } 468 }
464 469
465 void RegisterChromeOnMachine(const InstallerState& installer_state, 470 void RegisterChromeOnMachine(const InstallerState& installer_state,
466 const Product& product, 471 const Product& product,
467 bool make_chrome_default) { 472 bool make_chrome_default) {
468 DCHECK(product.is_chrome()); 473 DCHECK(product.is_chrome());
469 474
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
694 if (app_host_path.empty()) 699 if (app_host_path.empty())
695 return false; 700 return false;
696 701
697 CommandLine cmd(app_host_path); 702 CommandLine cmd(app_host_path);
698 cmd.AppendSwitchASCII(::switches::kInstallFromWebstore, app_code); 703 cmd.AppendSwitchASCII(::switches::kInstallFromWebstore, app_code);
699 VLOG(1) << "App install command: " << cmd.GetCommandLineString(); 704 VLOG(1) << "App install command: " << cmd.GetCommandLineString();
700 return base::LaunchProcess(cmd, base::LaunchOptions(), NULL); 705 return base::LaunchProcess(cmd, base::LaunchOptions(), NULL);
701 } 706 }
702 707
703 } // namespace installer 708 } // namespace installer
OLDNEW
« no previous file with comments | « chrome/browser/chrome_browser_main_win.cc ('k') | chrome/installer/util/browser_distribution.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698