| 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/profiles/profile_manager.h" | 5 #include "chrome/browser/profiles/profile_manager.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| 11 #include "base/debug/trace_event.h" | 11 #include "base/debug/trace_event.h" |
| 12 #include "base/deferred_sequenced_task_runner.h" | 12 #include "base/deferred_sequenced_task_runner.h" |
| 13 #include "base/files/file_enumerator.h" | 13 #include "base/files/file_enumerator.h" |
| 14 #include "base/files/file_path.h" | 14 #include "base/files/file_path.h" |
| 15 #include "base/files/file_util.h" | 15 #include "base/files/file_util.h" |
| 16 #include "base/metrics/histogram.h" | 16 #include "base/metrics/histogram.h" |
| 17 #include "base/prefs/pref_service.h" | 17 #include "base/prefs/pref_service.h" |
| 18 #include "base/prefs/scoped_user_pref_update.h" | 18 #include "base/prefs/scoped_user_pref_update.h" |
| 19 #include "base/strings/string_number_conversions.h" | 19 #include "base/strings/string_number_conversions.h" |
| 20 #include "base/strings/string_util.h" | 20 #include "base/strings/string_util.h" |
| 21 #include "base/strings/utf_string_conversions.h" | 21 #include "base/strings/utf_string_conversions.h" |
| 22 #include "chrome/browser/bookmarks/bookmark_model_factory.h" | 22 #include "chrome/browser/bookmarks/bookmark_model_factory.h" |
| 23 #include "chrome/browser/browser_process.h" | 23 #include "chrome/browser/browser_process.h" |
| 24 #include "chrome/browser/chrome_notification_types.h" | 24 #include "chrome/browser/chrome_notification_types.h" |
| 25 #include "chrome/browser/content_settings/host_content_settings_map.h" | |
| 26 #include "chrome/browser/download/download_service.h" | 25 #include "chrome/browser/download/download_service.h" |
| 27 #include "chrome/browser/download/download_service_factory.h" | 26 #include "chrome/browser/download/download_service_factory.h" |
| 28 #include "chrome/browser/password_manager/password_store_factory.h" | 27 #include "chrome/browser/password_manager/password_store_factory.h" |
| 29 #include "chrome/browser/prefs/incognito_mode_prefs.h" | 28 #include "chrome/browser/prefs/incognito_mode_prefs.h" |
| 30 #include "chrome/browser/profiles/bookmark_model_loaded_observer.h" | 29 #include "chrome/browser/profiles/bookmark_model_loaded_observer.h" |
| 31 #include "chrome/browser/profiles/profile_avatar_icon_util.h" | 30 #include "chrome/browser/profiles/profile_avatar_icon_util.h" |
| 32 #include "chrome/browser/profiles/profile_destroyer.h" | 31 #include "chrome/browser/profiles/profile_destroyer.h" |
| 33 #include "chrome/browser/profiles/profile_info_cache.h" | 32 #include "chrome/browser/profiles/profile_info_cache.h" |
| 34 #include "chrome/browser/profiles/profile_metrics.h" | 33 #include "chrome/browser/profiles/profile_metrics.h" |
| 35 #include "chrome/browser/profiles/profiles_state.h" | 34 #include "chrome/browser/profiles/profiles_state.h" |
| 36 #include "chrome/browser/profiles/startup_task_runner_service.h" | 35 #include "chrome/browser/profiles/startup_task_runner_service.h" |
| 37 #include "chrome/browser/profiles/startup_task_runner_service_factory.h" | 36 #include "chrome/browser/profiles/startup_task_runner_service_factory.h" |
| 38 #include "chrome/browser/signin/account_reconcilor_factory.h" | 37 #include "chrome/browser/signin/account_reconcilor_factory.h" |
| 39 #include "chrome/browser/signin/account_tracker_service_factory.h" | 38 #include "chrome/browser/signin/account_tracker_service_factory.h" |
| 40 #include "chrome/browser/sync/profile_sync_service.h" | 39 #include "chrome/browser/sync/profile_sync_service.h" |
| 41 #include "chrome/browser/sync/profile_sync_service_factory.h" | 40 #include "chrome/browser/sync/profile_sync_service_factory.h" |
| 42 #include "chrome/browser/ui/browser.h" | 41 #include "chrome/browser/ui/browser.h" |
| 43 #include "chrome/browser/ui/browser_iterator.h" | 42 #include "chrome/browser/ui/browser_iterator.h" |
| 44 #include "chrome/browser/ui/sync/sync_promo_ui.h" | 43 #include "chrome/browser/ui/sync/sync_promo_ui.h" |
| 45 #include "chrome/common/chrome_constants.h" | 44 #include "chrome/common/chrome_constants.h" |
| 46 #include "chrome/common/chrome_paths_internal.h" | 45 #include "chrome/common/chrome_paths_internal.h" |
| 47 #include "chrome/common/chrome_switches.h" | 46 #include "chrome/common/chrome_switches.h" |
| 48 #include "chrome/common/logging_chrome.h" | 47 #include "chrome/common/logging_chrome.h" |
| 49 #include "chrome/common/pref_names.h" | 48 #include "chrome/common/pref_names.h" |
| 50 #include "chrome/common/url_constants.h" | 49 #include "chrome/common/url_constants.h" |
| 51 #include "chrome/grit/generated_resources.h" | 50 #include "chrome/grit/generated_resources.h" |
| 52 #include "components/bookmarks/browser/bookmark_model.h" | 51 #include "components/bookmarks/browser/bookmark_model.h" |
| 52 #include "components/content_settings/core/browser/host_content_settings_map.h" |
| 53 #include "components/password_manager/core/browser/password_store.h" | 53 #include "components/password_manager/core/browser/password_store.h" |
| 54 #include "components/signin/core/common/profile_management_switches.h" | 54 #include "components/signin/core/common/profile_management_switches.h" |
| 55 #include "content/public/browser/browser_thread.h" | 55 #include "content/public/browser/browser_thread.h" |
| 56 #include "content/public/browser/notification_service.h" | 56 #include "content/public/browser/notification_service.h" |
| 57 #include "content/public/browser/user_metrics.h" | 57 #include "content/public/browser/user_metrics.h" |
| 58 #include "net/http/http_transaction_factory.h" | 58 #include "net/http/http_transaction_factory.h" |
| 59 #include "net/url_request/url_request_context.h" | 59 #include "net/url_request/url_request_context.h" |
| 60 #include "net/url_request/url_request_context_getter.h" | 60 #include "net/url_request/url_request_context_getter.h" |
| 61 #include "net/url_request/url_request_job.h" | 61 #include "net/url_request/url_request_job.h" |
| 62 #include "ui/base/l10n/l10n_util.h" | 62 #include "ui/base/l10n/l10n_util.h" |
| (...skipping 1258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1321 last_non_supervised_profile_path.BaseName().MaybeAsASCII()); | 1321 last_non_supervised_profile_path.BaseName().MaybeAsASCII()); |
| 1322 FinishDeletingProfile(profile_to_delete_path); | 1322 FinishDeletingProfile(profile_to_delete_path); |
| 1323 } | 1323 } |
| 1324 } | 1324 } |
| 1325 } | 1325 } |
| 1326 #endif | 1326 #endif |
| 1327 | 1327 |
| 1328 ProfileManagerWithoutInit::ProfileManagerWithoutInit( | 1328 ProfileManagerWithoutInit::ProfileManagerWithoutInit( |
| 1329 const base::FilePath& user_data_dir) : ProfileManager(user_data_dir) { | 1329 const base::FilePath& user_data_dir) : ProfileManager(user_data_dir) { |
| 1330 } | 1330 } |
| OLD | NEW |