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 "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/environment.h" | 10 #include "base/environment.h" |
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
344 // unless otherwise specified. | 344 // unless otherwise specified. |
345 if (!command_line_.HasSwitch(switches::kNoEvents)) { | 345 if (!command_line_.HasSwitch(switches::kNoEvents)) { |
346 FilePath script_path; | 346 FilePath script_path; |
347 PathService::Get(chrome::FILE_RECORDED_SCRIPT, &script_path); | 347 PathService::Get(chrome::FILE_RECORDED_SCRIPT, &script_path); |
348 | 348 |
349 bool record_mode = command_line_.HasSwitch(switches::kRecordMode); | 349 bool record_mode = command_line_.HasSwitch(switches::kRecordMode); |
350 bool playback_mode = command_line_.HasSwitch(switches::kPlaybackMode); | 350 bool playback_mode = command_line_.HasSwitch(switches::kPlaybackMode); |
351 | 351 |
352 if (record_mode && chrome::kRecordModeEnabled) | 352 if (record_mode && chrome::kRecordModeEnabled) |
353 base::EventRecorder::current()->StartRecording(script_path); | 353 base::EventRecorder::current()->StartRecording(script_path); |
354 if (playback_mode) | 354 // Do not enter Playback mode if PageCycler is running; Playback mode does |
| 355 // not work correctly. |
| 356 if (playback_mode && !command_line_.HasSwitch(switches::kVisitURLs)) |
355 base::EventRecorder::current()->StartPlayback(script_path); | 357 base::EventRecorder::current()->StartPlayback(script_path); |
356 } | 358 } |
357 | 359 |
358 #if defined(OS_WIN) | 360 #if defined(OS_WIN) |
359 if (process_startup) | 361 if (process_startup) |
360 ShellIntegration::MigrateChromiumShortcuts(); | 362 ShellIntegration::MigrateChromiumShortcuts(); |
361 #endif // defined(OS_WIN) | 363 #endif // defined(OS_WIN) |
362 | 364 |
363 return true; | 365 return true; |
364 } | 366 } |
(...skipping 489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
854 // New: | 856 // New: |
855 prefs->GetString(prefs::kHomePage), | 857 prefs->GetString(prefs::kHomePage), |
856 prefs->GetBoolean(prefs::kHomePageIsNewTabPage), | 858 prefs->GetBoolean(prefs::kHomePageIsNewTabPage), |
857 prefs->GetBoolean(prefs::kShowHomeButton), | 859 prefs->GetBoolean(prefs::kShowHomeButton), |
858 // Backup: | 860 // Backup: |
859 backup_homepage, | 861 backup_homepage, |
860 backup_homepage_is_ntp, | 862 backup_homepage_is_ntp, |
861 backup_show_home_button)); | 863 backup_show_home_button)); |
862 } | 864 } |
863 } | 865 } |
OLD | NEW |