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

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

Issue 2281743002: arc: Add support of default and OEM apps. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: clean 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/arc/arc_app_utils.cc
diff --git a/chrome/browser/ui/app_list/arc/arc_app_utils.cc b/chrome/browser/ui/app_list/arc/arc_app_utils.cc
index 94e69c14130ea9285aa349d6eb9bf228ebebce1b..d7806378b2a8e228da6d6e800e6d84855baa6af5 100644
--- a/chrome/browser/ui/app_list/arc/arc_app_utils.cc
+++ b/chrome/browser/ui/app_list/arc/arc_app_utils.cc
@@ -222,6 +222,17 @@ bool LaunchApp(content::BrowserContext* context,
if (!ash::Shell::HasInstance())
return false;
+ ArcAuthService* auth_service = ArcAuthService::Get();
+ DCHECK(auth_service);
+
+ if (!auth_service->IsArcEnabled()) {
xiyuan 2016/08/26 19:32:30 Can we limit this to only default apps?
khmel 2016/08/26 23:26:18 Actually we should have here only default apps. So
+ auth_service->EnableArc();
+ if (!auth_service->IsArcEnabled()) {
+ NOTREACHED();
+ return false;
+ }
+ }
+
ChromeLauncherController* chrome_controller =
ChromeLauncherController::instance();
DCHECK(chrome_controller);

Powered by Google App Engine
This is Rietveld 408576698