Commit 7138e8de authored by Daniel Murphy's avatar Daniel Murphy Committed by Commit Bot

[BMO] Implementing ShowAppInfo for BMO apps in chrome://apps

This hooks up the 'Show App Info' option in the context menu to work
for BMO-enabled apps.

R=loyso@chromium.org

Bug: 1009302
Change-Id: I18ce0848c7cddfa46137cd67bee9bff0e1d99771
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2121437Reviewed-by: default avatarcalamity <calamity@chromium.org>
Reviewed-by: default avatarAlexey Baskakov <loyso@chromium.org>
Commit-Queue: Daniel Murphy <dmurph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#757919}
parent cf91c1d2
......@@ -953,9 +953,10 @@ void AppLauncherHandler::HandleShowAppInfo(const base::ListValue* args) {
std::string extension_id;
CHECK(args->GetString(0, &extension_id));
if (DesktopPWAsWithoutExtensions() &&
web_app_provider_->registrar().IsInstalled(extension_id)) {
NOTIMPLEMENTED();
if (web_app_provider_->registrar().IsInstalled(extension_id)) {
chrome::ShowSiteSettings(
chrome::FindBrowserWithWebContents(web_ui()->GetWebContents()),
web_app_provider_->registrar().GetAppLaunchURL(extension_id));
return;
}
......@@ -967,13 +968,7 @@ void AppLauncherHandler::HandleShowAppInfo(const base::ListValue* args) {
extensions::ExtensionRegistry::TERMINATED);
if (!extension)
return;
if (extension->is_hosted_app() && extension->from_bookmark()) {
chrome::ShowSiteSettings(
chrome::FindBrowserWithWebContents(web_ui()->GetWebContents()),
extensions::AppLaunchInfo::GetFullLaunchURL(extension));
return;
}
DCHECK(!extension->from_bookmark());
UMA_HISTOGRAM_ENUMERATION("Apps.AppInfoDialog.Launches",
AppInfoLaunchSource::FROM_APPS_PAGE,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment