| 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 "base/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "build/build_config.h" | 6 #include "build/build_config.h" |
| 7 #include "chrome/browser/about_flags.h" | 7 #include "chrome/browser/about_flags.h" |
| 8 #include "chrome/browser/bookmarks/bookmark_model_factory.h" | 8 #include "chrome/browser/bookmarks/bookmark_model_factory.h" |
| 9 #include "chrome/browser/browser_process.h" | 9 #include "chrome/browser/browser_process.h" |
| 10 #include "chrome/browser/extensions/api/storage/settings_frontend.h" | 10 #include "chrome/browser/extensions/api/storage/settings_frontend.h" |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 50 #include "chrome/browser/sync/glue/ui_data_type_controller.h" | 50 #include "chrome/browser/sync/glue/ui_data_type_controller.h" |
| 51 #include "chrome/browser/sync/profile_sync_components_factory_impl.h" | 51 #include "chrome/browser/sync/profile_sync_components_factory_impl.h" |
| 52 #include "chrome/browser/sync/profile_sync_service.h" | 52 #include "chrome/browser/sync/profile_sync_service.h" |
| 53 #include "chrome/browser/sync/profile_sync_service_factory.h" | 53 #include "chrome/browser/sync/profile_sync_service_factory.h" |
| 54 #include "chrome/browser/sync/sessions2/session_data_type_controller2.h" | 54 #include "chrome/browser/sync/sessions2/session_data_type_controller2.h" |
| 55 #include "chrome/browser/themes/theme_service.h" | 55 #include "chrome/browser/themes/theme_service.h" |
| 56 #include "chrome/browser/themes/theme_service_factory.h" | 56 #include "chrome/browser/themes/theme_service_factory.h" |
| 57 #include "chrome/browser/themes/theme_syncable_service.h" | 57 #include "chrome/browser/themes/theme_syncable_service.h" |
| 58 #include "chrome/browser/webdata/autocomplete_syncable_service.h" | 58 #include "chrome/browser/webdata/autocomplete_syncable_service.h" |
| 59 #include "chrome/browser/webdata/autofill_profile_syncable_service.h" | 59 #include "chrome/browser/webdata/autofill_profile_syncable_service.h" |
| 60 #include "chrome/browser/webdata/web_data_service_factory.h" |
| 60 #include "chrome/common/chrome_switches.h" | 61 #include "chrome/common/chrome_switches.h" |
| 61 #include "chrome/common/pref_names.h" | 62 #include "chrome/common/pref_names.h" |
| 62 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" | 63 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" |
| 63 #include "components/dom_distiller/content/dom_distiller_service_factory.h" | 64 #include "components/dom_distiller/content/dom_distiller_service_factory.h" |
| 64 #include "components/dom_distiller/core/dom_distiller_service.h" | 65 #include "components/dom_distiller/core/dom_distiller_service.h" |
| 65 #include "content/public/browser/browser_thread.h" | 66 #include "content/public/browser/browser_thread.h" |
| 66 #include "sync/api/syncable_service.h" | 67 #include "sync/api/syncable_service.h" |
| 67 | 68 |
| 68 #if defined(ENABLE_MANAGED_USERS) | 69 #if defined(ENABLE_MANAGED_USERS) |
| 69 #include "chrome/browser/managed_mode/managed_user_service.h" | 70 #include "chrome/browser/managed_mode/managed_user_service.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 using browser_sync::UIDataTypeController; | 115 using browser_sync::UIDataTypeController; |
| 115 using content::BrowserThread; | 116 using content::BrowserThread; |
| 116 | 117 |
| 117 ProfileSyncComponentsFactoryImpl::ProfileSyncComponentsFactoryImpl( | 118 ProfileSyncComponentsFactoryImpl::ProfileSyncComponentsFactoryImpl( |
| 118 Profile* profile, CommandLine* command_line) | 119 Profile* profile, CommandLine* command_line) |
| 119 : profile_(profile), | 120 : profile_(profile), |
| 120 command_line_(command_line), | 121 command_line_(command_line), |
| 121 extension_system_( | 122 extension_system_( |
| 122 extensions::ExtensionSystemFactory::GetForProfile(profile)), | 123 extensions::ExtensionSystemFactory::GetForProfile(profile)), |
| 123 web_data_service_( | 124 web_data_service_( |
| 124 autofill::AutofillWebDataService::FromBrowserContext(profile_)) { | 125 WebDataServiceFactory::GetAutofillWebDataForProfile( |
| 126 profile_, Profile::EXPLICIT_ACCESS)) { |
| 125 } | 127 } |
| 126 | 128 |
| 127 ProfileSyncComponentsFactoryImpl::~ProfileSyncComponentsFactoryImpl() { | 129 ProfileSyncComponentsFactoryImpl::~ProfileSyncComponentsFactoryImpl() { |
| 128 } | 130 } |
| 129 | 131 |
| 130 void ProfileSyncComponentsFactoryImpl::RegisterDataTypes( | 132 void ProfileSyncComponentsFactoryImpl::RegisterDataTypes( |
| 131 ProfileSyncService* pss) { | 133 ProfileSyncService* pss) { |
| 132 RegisterCommonDataTypes(pss); | 134 RegisterCommonDataTypes(pss); |
| 133 #if !defined(OS_ANDROID) | 135 #if !defined(OS_ANDROID) |
| 134 RegisterDesktopDataTypes(pss); | 136 RegisterDesktopDataTypes(pss); |
| (...skipping 370 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 505 ProfileSyncComponentsFactory::SyncComponents | 507 ProfileSyncComponentsFactory::SyncComponents |
| 506 ProfileSyncComponentsFactoryImpl::CreateSessionSyncComponents( | 508 ProfileSyncComponentsFactoryImpl::CreateSessionSyncComponents( |
| 507 ProfileSyncService* profile_sync_service, | 509 ProfileSyncService* profile_sync_service, |
| 508 DataTypeErrorHandler* error_handler) { | 510 DataTypeErrorHandler* error_handler) { |
| 509 SessionModelAssociator* model_associator = | 511 SessionModelAssociator* model_associator = |
| 510 new SessionModelAssociator(profile_sync_service, error_handler); | 512 new SessionModelAssociator(profile_sync_service, error_handler); |
| 511 SessionChangeProcessor* change_processor = | 513 SessionChangeProcessor* change_processor = |
| 512 new SessionChangeProcessor(error_handler, model_associator); | 514 new SessionChangeProcessor(error_handler, model_associator); |
| 513 return SyncComponents(model_associator, change_processor); | 515 return SyncComponents(model_associator, change_processor); |
| 514 } | 516 } |
| OLD | NEW |