| 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..4a88c66f8cac21b3bfae6b3ecca770f665ba8164 100644
|
| --- a/chrome/browser/ui/app_list/app_list_syncable_service.cc
|
| +++ b/chrome/browser/ui/app_list/app_list_syncable_service.cc
|
| @@ -37,6 +37,7 @@
|
| #include "ui/base/l10n/l10n_util.h"
|
|
|
| #if defined(OS_CHROMEOS)
|
| +#include "chrome/browser/chromeos/arc/arc_auth_service.h"
|
| #include "chrome/browser/chromeos/file_manager/app_id.h"
|
| #include "chrome/browser/chromeos/genius_app/app_id.h"
|
| #include "chrome/browser/ui/app_list/arc/arc_app_item.h"
|
| @@ -219,6 +220,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) {
|
| + // 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());
|
| }
|
|
|
|
|