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

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

Issue 8734016: Make platform apps use and require a different container ("shell" instead of "panel") (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 9 years, 1 month 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
« no previous file with comments | « chrome/chrome_tests.gypi ('k') | chrome/common/extensions/extension_constants.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/extension.cc
diff --git a/chrome/common/extensions/extension.cc b/chrome/common/extensions/extension.cc
index 65d123410855250ce83085c1954fc4ce66036dc8..7a3c8ec45b2e893a879a6c6f0ac67809e4ca4499 100644
--- a/chrome/common/extensions/extension.cc
+++ b/chrome/common/extensions/extension.cc
@@ -1105,7 +1105,9 @@ bool Extension::LoadLaunchContainer(const DictionaryValue* manifest,
return false;
}
- if (launch_container_string == values::kLaunchContainerPanel) {
+ if (launch_container_string == values::kLaunchContainerShell) {
+ launch_container_ = extension_misc::LAUNCH_SHELL;
+ } else if (launch_container_string == values::kLaunchContainerPanel) {
launch_container_ = extension_misc::LAUNCH_PANEL;
} else if (launch_container_string == values::kLaunchContainerTab) {
launch_container_ = extension_misc::LAUNCH_TAB;
@@ -1549,10 +1551,13 @@ bool Extension::InitFromValue(const DictionaryValue& source, int flags,
}
if (is_platform_app_) {
- if (launch_container() != extension_misc::LAUNCH_PANEL) {
+ if (launch_container() != extension_misc::LAUNCH_SHELL) {
*error = errors::kInvalidLaunchContainerForPlatform;
return false;
}
+ } else if (launch_container() == extension_misc::LAUNCH_SHELL) {
+ *error = errors::kInvalidLaunchContainerForNonPlatform;
+ return false;
}
// Initialize the permissions (optional).
« no previous file with comments | « chrome/chrome_tests.gypi ('k') | chrome/common/extensions/extension_constants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698