Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(88)

Side by Side Diff: chrome/browser/sync/chrome_sync_client.cc

Issue 2250753002: arc: Fix ArcPackageSyncableService initialization issue. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/sync/test/integration/migration_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/sync/chrome_sync_client.h" 5 #include "chrome/browser/sync/chrome_sync_client.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 13 matching lines...) Expand all
24 #include "chrome/browser/profiles/profile_manager.h" 24 #include "chrome/browser/profiles/profile_manager.h"
25 #include "chrome/browser/search_engines/template_url_service_factory.h" 25 #include "chrome/browser/search_engines/template_url_service_factory.h"
26 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h" 26 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h"
27 #include "chrome/browser/sync/glue/sync_start_util.h" 27 #include "chrome/browser/sync/glue/sync_start_util.h"
28 #include "chrome/browser/sync/glue/theme_data_type_controller.h" 28 #include "chrome/browser/sync/glue/theme_data_type_controller.h"
29 #include "chrome/browser/sync/profile_sync_service_factory.h" 29 #include "chrome/browser/sync/profile_sync_service_factory.h"
30 #include "chrome/browser/sync/sessions/notification_service_sessions_router.h" 30 #include "chrome/browser/sync/sessions/notification_service_sessions_router.h"
31 #include "chrome/browser/themes/theme_service.h" 31 #include "chrome/browser/themes/theme_service.h"
32 #include "chrome/browser/themes/theme_service_factory.h" 32 #include "chrome/browser/themes/theme_service_factory.h"
33 #include "chrome/browser/themes/theme_syncable_service.h" 33 #include "chrome/browser/themes/theme_syncable_service.h"
34 #include "chrome/browser/ui/app_list/arc/arc_package_sync_data_type_controller.h "
34 #include "chrome/browser/ui/sync/browser_synced_window_delegates_getter.h" 35 #include "chrome/browser/ui/sync/browser_synced_window_delegates_getter.h"
35 #include "chrome/browser/undo/bookmark_undo_service_factory.h" 36 #include "chrome/browser/undo/bookmark_undo_service_factory.h"
36 #include "chrome/browser/web_data_service_factory.h" 37 #include "chrome/browser/web_data_service_factory.h"
37 #include "chrome/common/channel_info.h" 38 #include "chrome/common/channel_info.h"
38 #include "chrome/common/features.h" 39 #include "chrome/common/features.h"
39 #include "chrome/common/pref_names.h" 40 #include "chrome/common/pref_names.h"
40 #include "chrome/common/url_constants.h" 41 #include "chrome/common/url_constants.h"
41 #include "components/autofill/core/browser/webdata/autocomplete_syncable_service .h" 42 #include "components/autofill/core/browser/webdata/autocomplete_syncable_service .h"
42 #include "components/autofill/core/browser/webdata/autofill_profile_syncable_ser vice.h" 43 #include "components/autofill/core/browser/webdata/autofill_profile_syncable_ser vice.h"
43 #include "components/autofill/core/browser/webdata/autofill_wallet_metadata_sync able_service.h" 44 #include "components/autofill/core/browser/webdata/autofill_wallet_metadata_sync able_service.h"
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 #endif 607 #endif
607 608
608 #if defined(OS_CHROMEOS) 609 #if defined(OS_CHROMEOS)
609 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 610 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
610 switches::kEnableWifiCredentialSync) && 611 switches::kEnableWifiCredentialSync) &&
611 !disabled_types.Has(syncer::WIFI_CREDENTIALS)) { 612 !disabled_types.Has(syncer::WIFI_CREDENTIALS)) {
612 sync_service->RegisterDataTypeController(new UIDataTypeController( 613 sync_service->RegisterDataTypeController(new UIDataTypeController(
613 ui_thread, error_callback, syncer::WIFI_CREDENTIALS, this)); 614 ui_thread, error_callback, syncer::WIFI_CREDENTIALS, this));
614 } 615 }
615 // TODO (lgcheng@) Add switch for this. 616 // TODO (lgcheng@) Add switch for this.
616 sync_service->RegisterDataTypeController(new UIDataTypeController( 617 sync_service->RegisterDataTypeController(new ArcPackageSyncDataTypeController(
617 ui_thread, error_callback, syncer::ARC_PACKAGE, this)); 618 syncer::ARC_PACKAGE, error_callback, this, profile_));
618 #endif 619 #endif
619 } 620 }
620 621
621 void ChromeSyncClient::RegisterAndroidDataTypes( 622 void ChromeSyncClient::RegisterAndroidDataTypes(
622 sync_driver::SyncService* sync_service, 623 sync_driver::SyncService* sync_service,
623 syncer::ModelTypeSet disabled_types, 624 syncer::ModelTypeSet disabled_types,
624 syncer::ModelTypeSet enabled_types) { 625 syncer::ModelTypeSet enabled_types) {
625 base::Closure error_callback = 626 base::Closure error_callback =
626 base::Bind(&ChromeReportUnrecoverableError, chrome::GetChannel()); 627 base::Bind(&ChromeReportUnrecoverableError, chrome::GetChannel());
627 #if defined(ENABLE_SUPERVISED_USERS) 628 #if defined(ENABLE_SUPERVISED_USERS)
628 sync_service->RegisterDataTypeController( 629 sync_service->RegisterDataTypeController(
629 new SupervisedUserSyncDataTypeController(syncer::SUPERVISED_USER_SETTINGS, 630 new SupervisedUserSyncDataTypeController(syncer::SUPERVISED_USER_SETTINGS,
630 error_callback, this, profile_)); 631 error_callback, this, profile_));
631 sync_service->RegisterDataTypeController( 632 sync_service->RegisterDataTypeController(
632 new SupervisedUserSyncDataTypeController( 633 new SupervisedUserSyncDataTypeController(
633 syncer::SUPERVISED_USER_WHITELISTS, error_callback, this, profile_)); 634 syncer::SUPERVISED_USER_WHITELISTS, error_callback, this, profile_));
634 #endif 635 #endif
635 } 636 }
636 637
637 } // namespace browser_sync 638 } // namespace browser_sync
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/sync/test/integration/migration_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698