| 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.h" | 5 #include "chrome/browser/ui/startup/startup_browser_creator.h" |
| 6 | 6 |
| 7 #include <algorithm> // For max(). | 7 #include <algorithm> // For max(). |
| 8 #include <set> | 8 #include <set> |
| 9 | 9 |
| 10 #include "apps/app_load_service.h" | 10 #include "apps/app_load_service.h" |
| 11 #include "apps/switches.h" | 11 #include "apps/switches.h" |
| 12 #include "base/bind.h" | 12 #include "base/bind.h" |
| 13 #include "base/bind_helpers.h" | 13 #include "base/bind_helpers.h" |
| 14 #include "base/command_line.h" | 14 #include "base/command_line.h" |
| 15 #include "base/compiler_specific.h" | 15 #include "base/compiler_specific.h" |
| 16 #include "base/environment.h" | 16 #include "base/environment.h" |
| 17 #include "base/files/file_path.h" | 17 #include "base/files/file_path.h" |
| 18 #include "base/files/file_util.h" | 18 #include "base/files/file_util.h" |
| 19 #include "base/lazy_instance.h" | 19 #include "base/lazy_instance.h" |
| 20 #include "base/logging.h" | 20 #include "base/logging.h" |
| 21 #include "base/memory/scoped_ptr.h" | 21 #include "base/memory/scoped_ptr.h" |
| 22 #include "base/metrics/histogram.h" | 22 #include "base/metrics/histogram.h" |
| 23 #include "base/metrics/statistics_recorder.h" | 23 #include "base/metrics/statistics_recorder.h" |
| 24 #include "base/path_service.h" | |
| 25 #include "base/prefs/pref_service.h" | 24 #include "base/prefs/pref_service.h" |
| 26 #include "base/strings/string_number_conversions.h" | 25 #include "base/strings/string_number_conversions.h" |
| 27 #include "base/strings/string_split.h" | 26 #include "base/strings/string_split.h" |
| 28 #include "base/strings/utf_string_conversions.h" | 27 #include "base/strings/utf_string_conversions.h" |
| 29 #include "base/threading/thread_restrictions.h" | 28 #include "base/threading/thread_restrictions.h" |
| 30 #include "chrome/browser/app_mode/app_mode_utils.h" | 29 #include "chrome/browser/app_mode/app_mode_utils.h" |
| 31 #include "chrome/browser/auto_launch_trial.h" | 30 #include "chrome/browser/auto_launch_trial.h" |
| 32 #include "chrome/browser/browser_process.h" | 31 #include "chrome/browser/browser_process.h" |
| 33 #include "chrome/browser/chrome_notification_types.h" | 32 #include "chrome/browser/chrome_notification_types.h" |
| 34 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" | 33 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" |
| (...skipping 711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 746 // If we are showing the app list then chrome isn't shown so load the app | 745 // If we are showing the app list then chrome isn't shown so load the app |
| 747 // list's profile rather than chrome's. | 746 // list's profile rather than chrome's. |
| 748 if (command_line.HasSwitch(switches::kShowAppList)) { | 747 if (command_line.HasSwitch(switches::kShowAppList)) { |
| 749 return AppListService::Get(chrome::HOST_DESKTOP_TYPE_NATIVE)-> | 748 return AppListService::Get(chrome::HOST_DESKTOP_TYPE_NATIVE)-> |
| 750 GetProfilePath(user_data_dir); | 749 GetProfilePath(user_data_dir); |
| 751 } | 750 } |
| 752 | 751 |
| 753 return g_browser_process->profile_manager()->GetLastUsedProfileDir( | 752 return g_browser_process->profile_manager()->GetLastUsedProfileDir( |
| 754 user_data_dir); | 753 user_data_dir); |
| 755 } | 754 } |
| OLD | NEW |