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

Unified Diff: chrome/browser/sync/glue/sync_backend_host.cc

Issue 8851004: [Sync] Replace all instances of ModelTypeBitSet with ModelEnumSet (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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 | « chrome/browser/sync/glue/sync_backend_host.h ('k') | chrome/browser/sync/internal_api/sync_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/glue/sync_backend_host.cc
diff --git a/chrome/browser/sync/glue/sync_backend_host.cc b/chrome/browser/sync/glue/sync_backend_host.cc
index ae90c19791f60b8b5920d7ac1127c04e3118e581..d2f86d0d7d6d0e75cdb8a27dd4b55aee2da36fc5 100644
--- a/chrome/browser/sync/glue/sync_backend_host.cc
+++ b/chrome/browser/sync/glue/sync_backend_host.cc
@@ -684,7 +684,7 @@ void SyncBackendHost::Core::DoShutdown(bool sync_disabled) {
}
void SyncBackendHost::Core::DoRequestConfig(
- const syncable::ModelTypeBitSet& types_to_config,
+ syncable::ModelEnumSet types_to_config,
sync_api::ConfigureReason reason) {
DCHECK_EQ(MessageLoop::current(), sync_loop_);
sync_manager_->RequestConfig(types_to_config, reason);
@@ -1011,22 +1011,24 @@ void SyncBackendHost::FinishConfigureDataTypesOnFrontendLoop() {
pending_download_state_.reset(pending_config_mode_state_.release());
// Always configure nigori if it's enabled.
- syncable::ModelTypeSet types_to_config =
- pending_download_state_->added_types;
+ syncable::ModelEnumSet types_to_config =
+ syncable::ModelTypeSetToEnumSet(
+ pending_download_state_->added_types);
if (IsNigoriEnabled()) {
// Note: Nigori is the only type that gets added with a nonempty
// progress marker during config. If the server returns a migration
// error then we will go into unrecoverable error. We dont handle it
// explicitly because server might help us out here by not sending a
// migraiton error for nigori during config.
- types_to_config.insert(syncable::NIGORI);
+ types_to_config.Put(syncable::NIGORI);
}
- SVLOG(1) << "Types " << ModelTypeSetToString(types_to_config)
+ SVLOG(1) << "Types "
+ << syncable::ModelEnumSetToString(types_to_config)
<< " added; calling DoRequestConfig";
sync_thread_.message_loop()->PostTask(FROM_HERE,
base::Bind(&SyncBackendHost::Core::DoRequestConfig,
core_.get(),
- syncable::ModelTypeBitSetFromSet(types_to_config),
+ types_to_config,
pending_download_state_->reason));
}
« no previous file with comments | « chrome/browser/sync/glue/sync_backend_host.h ('k') | chrome/browser/sync/internal_api/sync_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698