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

Unified Diff: chrome/browser/ui/app_list/app_list_syncable_service.cc

Issue 2295343002: arc: Dont sync app list change caused by Arc opt out. (Closed)
Patch Set: Created 4 years, 4 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/ui/app_list/app_list_syncable_service.cc
diff --git a/chrome/browser/ui/app_list/app_list_syncable_service.cc b/chrome/browser/ui/app_list/app_list_syncable_service.cc
index 97db26e0bff4e6158be83de2c0e6fe3c12ebb34f..2012a69a3f03dbeb72654d6640b822636dab1e90 100644
--- a/chrome/browser/ui/app_list/app_list_syncable_service.cc
+++ b/chrome/browser/ui/app_list/app_list_syncable_service.cc
@@ -219,6 +219,17 @@ class AppListSyncableService::ModelObserver : public AppListModelObserver {
// deleted when the last item is removed (in PruneEmptySyncFolders()).
if (item->GetItemType() == AppListFolderItem::kItemType)
return;
+
+#if defined(OS_CHROMEOS)
+ if (item->GetItemType() == ArcAppItem::kItemType) {
khmel 2016/08/31 20:31:48 I tried first not to modify AppListSync but OnAppL
stevenjb 2016/08/31 21:10:49 This seems reasonable. We already have arc related
xiyuan 2016/08/31 21:43:09 nit: fix indent
khmel 2016/09/01 00:03:02 Thanks, will create additional CL to move ArcAuthS
khmel 2016/09/01 00:03:02 Done.
+ // Don't sync remove changes coming as result of disabling Arc.
+ const arc::ArcAuthService* auth_service = arc::ArcAuthService::Get();
+ DCHECK(auth_service);
+ if (!auth_service->IsArcEnabled())
+ return;
+ }
+#endif
+
owner_->RemoveSyncItem(item->id());
}

Powered by Google App Engine
This is Rietveld 408576698