Chromium Code Reviews| 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/browser/ui/startup/startup_browser_creator_impl.h" | 5 #include "chrome/browser/ui/startup/startup_browser_creator_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "apps/app_restore_service.h" | 10 #include "apps/app_restore_service.h" |
| (...skipping 500 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 511 return (app_tab != NULL); | 511 return (app_tab != NULL); |
| 512 } | 512 } |
| 513 } | 513 } |
| 514 return false; | 514 return false; |
| 515 } | 515 } |
| 516 | 516 |
| 517 void StartupBrowserCreatorImpl::ProcessLaunchURLs( | 517 void StartupBrowserCreatorImpl::ProcessLaunchURLs( |
| 518 bool process_startup, | 518 bool process_startup, |
| 519 const std::vector<GURL>& urls_to_open, | 519 const std::vector<GURL>& urls_to_open, |
| 520 chrome::HostDesktopType desktop_type) { | 520 chrome::HostDesktopType desktop_type) { |
| 521 #if defined(USE_ATHENA) | |
| 522 // TODO(dpolukhin): make session restore for Athena. | |
|
oshima
2014/09/04 16:14:28
StartAthenaSessionWithContext should take care of
Dmitry Polukhin
2014/09/05 15:05:00
Done.
| |
| 523 return; | |
| 524 #endif | |
| 525 | |
| 521 // If we're starting up in "background mode" (no open browser window) then | 526 // If we're starting up in "background mode" (no open browser window) then |
| 522 // don't open any browser windows, unless kAutoLaunchAtStartup is also | 527 // don't open any browser windows, unless kAutoLaunchAtStartup is also |
| 523 // specified. | 528 // specified. |
| 524 if (process_startup && | 529 if (process_startup && |
| 525 command_line_.HasSwitch(switches::kNoStartupWindow) && | 530 command_line_.HasSwitch(switches::kNoStartupWindow) && |
| 526 !command_line_.HasSwitch(switches::kAutoLaunchAtStartup)) { | 531 !command_line_.HasSwitch(switches::kAutoLaunchAtStartup)) { |
| 527 return; | 532 return; |
| 528 } | 533 } |
| 529 | 534 |
| 530 // TODO(tapted): Move this to startup_browser_creator_win.cc after refactor. | 535 // TODO(tapted): Move this to startup_browser_creator_win.cc after refactor. |
| (...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 915 // behavior is desired because completing or skipping the sync promo | 920 // behavior is desired because completing or skipping the sync promo |
| 916 // causes a redirect to the NTP. | 921 // causes a redirect to the NTP. |
| 917 if (!startup_urls->empty() && | 922 if (!startup_urls->empty() && |
| 918 startup_urls->at(0) == GURL(chrome::kChromeUINewTabURL)) | 923 startup_urls->at(0) == GURL(chrome::kChromeUINewTabURL)) |
| 919 startup_urls->at(0) = sync_promo_url; | 924 startup_urls->at(0) = sync_promo_url; |
| 920 else | 925 else |
| 921 startup_urls->insert(startup_urls->begin(), sync_promo_url); | 926 startup_urls->insert(startup_urls->begin(), sync_promo_url); |
| 922 } | 927 } |
| 923 } | 928 } |
| 924 } | 929 } |
| OLD | NEW |