Add load-app flag support to chrome
BUG=432359
Review URL: https://codereview.chromium.org/718133005
Cr-Commit-Position: refs/heads/master@{#305688}
diff --git a/apps/app_load_service.cc b/apps/app_load_service.cc
index 8f22422..c4d308e 100644
--- a/apps/app_load_service.cc
+++ b/apps/app_load_service.cc
@@ -77,6 +77,14 @@
return true;
}
+bool AppLoadService::Load(const base::FilePath& extension_path) {
+ ExtensionService* extension_service =
+ ExtensionSystem::Get(profile_)->extension_service();
+ std::string extension_id;
+ return extensions::UnpackedInstaller::Create(extension_service)->
+ LoadFromCommandLine(base::FilePath(extension_path), &extension_id);
+}
+
// static
AppLoadService* AppLoadService::Get(Profile* profile) {
return apps::AppLoadServiceFactory::GetForProfile(profile);