summaryrefslogtreecommitdiff
path: root/chromium/components/browser_sync/profile_sync_components_factory_impl.cc
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2017-07-17 13:57:45 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2017-07-19 13:44:40 +0000
commit6ec7b8da05d21a3878bd21c691b41e675d74bb1c (patch)
treeb87f250bc19413750b9bb9cdbf2da20ef5014820 /chromium/components/browser_sync/profile_sync_components_factory_impl.cc
parentec02ee4181c49b61fce1c8fb99292dbb8139cc90 (diff)
downloadqtwebengine-chromium-6ec7b8da05d21a3878bd21c691b41e675d74bb1c.tar.gz
BASELINE: Update Chromium to 60.0.3112.70
Change-Id: I9911c2280a014d4632f254857876a395d4baed2d Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'chromium/components/browser_sync/profile_sync_components_factory_impl.cc')
-rw-r--r--chromium/components/browser_sync/profile_sync_components_factory_impl.cc13
1 files changed, 11 insertions, 2 deletions
diff --git a/chromium/components/browser_sync/profile_sync_components_factory_impl.cc b/chromium/components/browser_sync/profile_sync_components_factory_impl.cc
index 445b20bb221..5f47d6185b4 100644
--- a/chromium/components/browser_sync/profile_sync_components_factory_impl.cc
+++ b/chromium/components/browser_sync/profile_sync_components_factory_impl.cc
@@ -9,6 +9,7 @@
#include "base/feature_list.h"
#include "base/memory/ptr_util.h"
#include "base/memory/ref_counted.h"
+#include "base/single_thread_task_runner.h"
#include "build/build_config.h"
#include "components/autofill/core/browser/autofill_wallet_data_type_controller.h"
#include "components/autofill/core/browser/webdata/autocomplete_sync_bridge.h"
@@ -49,6 +50,7 @@
#include "google_apis/gaia/oauth2_token_service_request.h"
#include "net/url_request/url_request_context_getter.h"
+using base::FeatureList;
using bookmarks::BookmarkModel;
using sync_bookmarks::BookmarkChangeProcessor;
using sync_bookmarks::BookmarkDataTypeController;
@@ -139,7 +141,7 @@ void ProfileSyncComponentsFactoryImpl::RegisterCommonDataTypes(
base::Bind(&syncer::ReportUnrecoverableError, channel_);
// TODO(stanisc): can DEVICE_INFO be one of disabled datatypes?
- if (base::FeatureList::IsEnabled(switches::kSyncUSSDeviceInfo)) {
+ if (FeatureList::IsEnabled(switches::kSyncUSSDeviceInfo)) {
// Use an error callback that always uploads a stacktrace if it can to help
// get USS as stable as possible.
sync_service->RegisterDataTypeController(
@@ -155,7 +157,7 @@ void ProfileSyncComponentsFactoryImpl::RegisterCommonDataTypes(
// Autocomplete sync is enabled by default. Register unless explicitly
// disabled.
if (!disabled_types.Has(syncer::AUTOFILL)) {
- if (base::FeatureList::IsEnabled(switches::kSyncUSSAutocomplete)) {
+ if (FeatureList::IsEnabled(switches::kSyncUSSAutocomplete)) {
sync_service->RegisterDataTypeController(
base::MakeUnique<autofill::WebDataModelTypeController>(
syncer::AUTOFILL, sync_client_, db_thread_, web_data_service_,
@@ -308,6 +310,13 @@ void ProfileSyncComponentsFactoryImpl::RegisterCommonDataTypes(
base::MakeUnique<ModelTypeController>(syncer::READING_LIST,
sync_client_, ui_thread_));
}
+
+ if (!disabled_types.Has(syncer::USER_EVENTS) &&
+ FeatureList::IsEnabled(switches::kSyncUserEvents)) {
+ sync_service->RegisterDataTypeController(
+ base::MakeUnique<ModelTypeController>(syncer::USER_EVENTS, sync_client_,
+ ui_thread_));
+ }
}
DataTypeManager* ProfileSyncComponentsFactoryImpl::CreateDataTypeManager(