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

Unified Diff: chrome/browser/ui/app_list/arc/arc_app_model_builder.cc

Issue 2702723002: Extract kArcEnabled preference from ArcSessionManager part 1. (Closed)
Patch Set: Address comments. Created 3 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: chrome/browser/ui/app_list/arc/arc_app_model_builder.cc
diff --git a/chrome/browser/ui/app_list/arc/arc_app_model_builder.cc b/chrome/browser/ui/app_list/arc/arc_app_model_builder.cc
index eaabcd7838ae529b46f9f8abe03e7741582a5421..29bc9059db4aa3f2cacb41f6b4b00ddd19df2e5c 100644
--- a/chrome/browser/ui/app_list/arc/arc_app_model_builder.cc
+++ b/chrome/browser/ui/app_list/arc/arc_app_model_builder.cc
@@ -5,7 +5,7 @@
#include "chrome/browser/ui/app_list/arc/arc_app_model_builder.h"
#include "base/memory/ptr_util.h"
-#include "chrome/browser/chromeos/arc/arc_session_manager.h"
+#include "chrome/browser/chromeos/arc/arc_util.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/app_list/arc/arc_app_item.h"
@@ -53,11 +53,9 @@ void ArcAppModelBuilder::OnAppRegistered(
}
void ArcAppModelBuilder::OnAppRemoved(const std::string& app_id) {
- const arc::ArcSessionManager* arc_session_manager =
- arc::ArcSessionManager::Get();
- DCHECK(arc_session_manager);
- // Don't sync app removal in case it was caused by disabling ARC.
- const bool unsynced_change = !arc_session_manager->IsArcPlayStoreEnabled();
+ // Don't sync app removal in case it was caused by disabling Google Play
+ // Store.
+ const bool unsynced_change = !arc::IsArcPlayStoreEnabledForProfile(profile());
RemoveApp(app_id, unsynced_change);
}
« no previous file with comments | « chrome/browser/ui/app_list/arc/arc_app_list_prefs.cc ('k') | chrome/browser/ui/app_list/arc/arc_app_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698