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

Unified Diff: components/sync/driver/ui_data_type_controller.cc

Issue 2257523003: [Sync] Move StartAssociation from NonUIDataTypeController to SharedChangeProcessor. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move local_service_ WeakPtr to SharedChangeProcessor. 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/sync/driver/shared_change_processor_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/sync/driver/ui_data_type_controller.cc
diff --git a/components/sync/driver/ui_data_type_controller.cc b/components/sync/driver/ui_data_type_controller.cc
index 584610ee288be4bb723cbd5b8f10bc6bf254af0c..abc3430b0cc490fae5dff3f8151048bae673bc01 100644
--- a/components/sync/driver/ui_data_type_controller.cc
+++ b/components/sync/driver/ui_data_type_controller.cc
@@ -70,7 +70,7 @@ void UIDataTypeController::LoadModels(
// Since we can't be called multiple times before Stop() is called,
// |shared_change_processor_| must be NULL here.
DCHECK(!shared_change_processor_.get());
- shared_change_processor_ = new SharedChangeProcessor();
+ shared_change_processor_ = new SharedChangeProcessor(type());
state_ = MODEL_STARTING;
if (!StartModels()) {
@@ -135,7 +135,7 @@ void UIDataTypeController::Associate() {
DCHECK(sync_client_->GetSyncService());
local_service_ = shared_change_processor_->Connect(
sync_client_, processor_factory_.get(),
- sync_client_->GetSyncService()->GetUserShare(), this, type(),
+ sync_client_->GetSyncService()->GetUserShare(), this,
weak_ptr_factory.GetWeakPtr());
if (!local_service_.get()) {
syncer::SyncError error(FROM_HERE, syncer::SyncError::DATATYPE_ERROR,
« no previous file with comments | « components/sync/driver/shared_change_processor_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698