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

Unified Diff: chrome/browser/sync/chrome_sync_client.cc

Issue 2740363002: [Sync] Fix EnableDisableSingleClientTest (Closed)
Patch Set: fix unit_tests Created 3 years, 9 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/chrome_sync_client.cc
diff --git a/chrome/browser/sync/chrome_sync_client.cc b/chrome/browser/sync/chrome_sync_client.cc
index 2571a605ca9bc29a0994bf68abbce6b70ff88f52..7daf2b925897267483eb02ff849cda75f7c05fd9 100644
--- a/chrome/browser/sync/chrome_sync_client.cc
+++ b/chrome/browser/sync/chrome_sync_client.cc
@@ -108,6 +108,7 @@
#endif
#if defined(OS_CHROMEOS)
+#include "chrome/browser/chromeos/arc/arc_util.h"
#include "chrome/browser/chromeos/printing/printers_manager.h"
#include "chrome/browser/chromeos/printing/printers_manager_factory.h"
#include "chrome/browser/chromeos/printing/printers_sync_bridge.h"
@@ -679,10 +680,11 @@ void ChromeSyncClient::RegisterDesktopDataTypes(
BrowserThread::GetTaskRunnerForThread(BrowserThread::UI)));
}
- // TODO(lgcheng): Add switch for this.
- sync_service->RegisterDataTypeController(
- base::MakeUnique<ArcPackageSyncDataTypeController>(
- syncer::ARC_PACKAGE, error_callback, this, profile_));
+ if (arc::IsArcAllowedForProfile(profile_)) {
lgcheng 2017/03/14 21:59:28 I am not sure about the test infrastructure. But I
Gang Wu 2017/03/15 07:55:45 Add a switch here not just for fixing test, but al
skym 2017/03/15 15:45:58 I think the piece of information you need to decid
lgcheng 2017/03/15 17:20:58 There are two stage for Enabling Arc. IsArcAllowed
Gang Wu 2017/03/16 18:40:30 If user can enable Arc at runtime, I think it is g
+ sync_service->RegisterDataTypeController(
+ base::MakeUnique<ArcPackageSyncDataTypeController>(
+ syncer::ARC_PACKAGE, error_callback, this, profile_));
+ }
#endif
}

Powered by Google App Engine
This is Rietveld 408576698