Chromium Code Reviews| Index: components/sync_driver/data_type_manager_impl.cc |
| diff --git a/components/sync_driver/data_type_manager_impl.cc b/components/sync_driver/data_type_manager_impl.cc |
| index 77545aa34359ae8e654ed705c80142306b16c8bf..e6d691ee75be6a5b5a7983efd1c27783f0930234 100644 |
| --- a/components/sync_driver/data_type_manager_impl.cc |
| +++ b/components/sync_driver/data_type_manager_impl.cc |
| @@ -111,6 +111,24 @@ void DataTypeManagerImpl::Configure(syncer::ModelTypeSet desired_types, |
| ConfigureImpl(filtered_desired_types, reason); |
| } |
| +void DataTypeManagerImpl::ReenableType(syncer::ModelType type) { |
| + // TODO(zea): move the "should we reconfigure" logic into the datatype handler |
| + // itself. |
| + // Only reconfigure if the type actually had a data type or unready error. |
| + if (!failed_data_types_handler_->ResetDataTypeErrorFor(type) && |
| + !failed_data_types_handler_->ResetUnreadyErrorFor(type)) { |
| + return; |
| + } |
| + |
| + // Only reconfigure if the type is actually desired. |
| + if (!last_requested_types_.Has(type)) |
| + return; |
| + |
| + DVLOG(1) << "Reenabling " << syncer::ModelTypeToString(type); |
| + needs_reconfigure_ = true; |
|
maniscalco
2014/08/04 23:59:30
The comment for last_configure_reason_ says that i
Nicolas Zea
2014/08/06 21:20:08
Good point. Added a new configure reason for progr
|
| + ProcessReconfigure(); |
| +} |
| + |
| void DataTypeManagerImpl::PurgeForMigration( |
| syncer::ModelTypeSet undesired_types, |
| syncer::ConfigureReason reason) { |