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

Unified Diff: chrome/common/extensions/extension.cc

Issue 10332071: Pass command line arguments onto platform apps which provide the right intent. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Windows tests fixed Created 8 years, 7 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/common/extensions/extension.cc
diff --git a/chrome/common/extensions/extension.cc b/chrome/common/extensions/extension.cc
index bd79d1c263d3dd9b25379ca5dc3d715858bfed5d..477764fa0a4c9f8fac09ca6130f22c237b49aa8f 100644
--- a/chrome/common/extensions/extension.cc
+++ b/chrome/common/extensions/extension.cc
@@ -1790,13 +1790,13 @@ bool Extension::LoadWebIntentAction(const std::string& action_name,
if (href.empty()) {
if (is_hosted_app()) {
href = launch_web_url();
- } else if (is_packaged_app() || is_platform_app()) {
+ } else if (is_packaged_app()) {
href = launch_local_path();
}
}
// If we still don't have an href, the manifest is malformed.
- if (href.empty()) {
+ if (href.empty() && !is_platform_app()) {
*error = ExtensionErrorUtils::FormatErrorMessageUTF16(
errors::kInvalidIntentHrefEmpty, action_name);
return false;
@@ -1812,7 +1812,7 @@ bool Extension::LoadWebIntentAction(const std::string& action_name,
return false;
}
service.service_url = service_url;
- } else {
+ } else if (!is_platform_app()) {
// We do not allow absolute intent URLs in non-hosted apps.
if (service_url.is_valid()) {
*error = ExtensionErrorUtils::FormatErrorMessageUTF16(
« no previous file with comments | « chrome/common/extensions/api/experimental_app.json ('k') | chrome/renderer/extensions/experimental.app_custom_bindings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698