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

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

Issue 1253743003: [Sync] Update SyncBackendHost to forward ClearServerData to SyncManager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@clearserverdatacommand
Patch Set: Remove unused callback variable Created 5 years, 5 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
Index: chrome/browser/sync/glue/sync_backend_host_core.cc
diff --git a/chrome/browser/sync/glue/sync_backend_host_core.cc b/chrome/browser/sync/glue/sync_backend_host_core.cc
index c0b962cec436be26d1efced2df2e0c3313c2cdb9..01688be44b988211eb6e4bc4637ea211ffdad5e9 100644
--- a/chrome/browser/sync/glue/sync_backend_host_core.cc
+++ b/chrome/browser/sync/glue/sync_backend_host_core.cc
@@ -743,4 +743,21 @@ void SyncBackendHostCore::SaveChanges() {
sync_manager_->SaveChanges();
}
+void SyncBackendHostCore::DoClearServerData(
+ const syncer::SyncManager::ClearServerDataCallback& frontend_callback) {
+ DCHECK_EQ(base::MessageLoop::current(), sync_loop_);
+ const syncer::SyncManager::ClearServerDataCallback callback =
+ base::Bind(&SyncBackendHostCore::ClearServerDataDone,
+ weak_ptr_factory_.GetWeakPtr(), frontend_callback);
+ sync_manager_->ClearServerData(callback);
+}
+
+void SyncBackendHostCore::ClearServerDataDone(
+ const base::Closure& frontend_callback) {
+ DCHECK_EQ(base::MessageLoop::current(), sync_loop_);
+ host_.Call(FROM_HERE, &SyncBackendHostImpl::ClearServerDataDoneOnFrontendLoop,
+ frontend_callback);
+}
+
+
} // namespace browser_sync
« no previous file with comments | « chrome/browser/sync/glue/sync_backend_host_core.h ('k') | chrome/browser/sync/glue/sync_backend_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698