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

Unified Diff: components/sync_driver/device_info_model_type_controller.cc

Issue 1717433002: [USS] Break NonBlockingDataTypeController into UI specific one and non-UI specific one (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: typo Created 4 years, 10 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: components/sync_driver/device_info_model_type_controller.cc
diff --git a/components/sync_driver/device_info_model_type_controller.cc b/components/sync_driver/device_info_model_type_controller.cc
index 3030fd7f7d0df5a7cdf3f9afa4fe2e3d279c8ff1..0e6a6c2f23d7b2e1cfe44ea83a8dd6f63fe958ba 100644
--- a/components/sync_driver/device_info_model_type_controller.cc
+++ b/components/sync_driver/device_info_model_type_controller.cc
@@ -18,24 +18,15 @@ DeviceInfoModelTypeController::DeviceInfoModelTypeController(
const base::Closure& error_callback,
SyncClient* sync_client,
LocalDeviceInfoProvider* local_device_info_provider)
- : NonBlockingDataTypeController(ui_thread,
- error_callback,
- syncer::DEVICE_INFO,
- sync_client),
- local_device_info_provider_(local_device_info_provider) {}
+ : UIModelTypeController(ui_thread,
+ error_callback,
+ syncer::DEVICE_INFO,
+ sync_client),
+ local_device_info_provider_(local_device_info_provider) {
+ // TODO(gangwu): find a better place to initial processor.
+ InitializeProcessor();
+}
DeviceInfoModelTypeController::~DeviceInfoModelTypeController() {}
-// TODO(gangwu):(crbug.com/558000) move this function to superclass.
-bool DeviceInfoModelTypeController::RunOnModelThread(
- const tracked_objects::Location& from_here,
- const base::Closure& task) {
- if (BelongsToUIThread()) {
- task.Run();
- } else {
- RunOnUIThread(from_here, task);
- }
- return true;
-}
-
} // namespace sync_driver_v2
« no previous file with comments | « components/sync_driver/device_info_model_type_controller.h ('k') | components/sync_driver/non_blocking_data_type_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698