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

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

Issue 1730013: fullscreen window app launch container (Closed)
Patch Set: added tests Created 10 years, 8 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
« no previous file with comments | « chrome/common/extensions/extension.h ('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 8e9d711ad6c9e2671663e105481d87b2f2ad6ce1..c7cb429c65c650c5e84b8c9bd1f6dafc72669aad 100644
--- a/chrome/common/extensions/extension.cc
+++ b/chrome/common/extensions/extension.cc
@@ -696,11 +696,26 @@ bool Extension::LoadLaunchContainer(const DictionaryValue* manifest,
return true;
}
+bool Extension::LoadLaunchFullscreen(const DictionaryValue* manifest,
+ std::string* error) {
+ Value* temp = NULL;
+ if (!manifest->Get(keys::kLaunchFullscreen, &temp))
+ return true;
+
+ if (!temp->GetAsBoolean(&launch_fullscreen_)) {
+ *error = errors::kInvalidLaunchFullscreen;
+ return false;
+ }
+
+ return true;
+}
+
Extension::Extension(const FilePath& path)
: converted_from_user_script_(false),
is_theme_(false),
web_content_enabled_(false),
launch_container_(LAUNCH_TAB),
+ launch_fullscreen_(false),
background_page_ready_(false),
being_upgraded_(false) {
DCHECK(path.IsAbsolute());
@@ -1433,7 +1448,8 @@ bool Extension::InitFromValue(const DictionaryValue& source, bool require_key,
!LoadWebOrigin(manifest_value_.get(), error) ||
!LoadWebPaths(manifest_value_.get(), error) ||
!LoadLaunchURL(manifest_value_.get(), error) ||
- !LoadLaunchContainer(manifest_value_.get(), error)) {
+ !LoadLaunchContainer(manifest_value_.get(), error) ||
+ !LoadLaunchFullscreen(manifest_value_.get(), error)) {
return false;
}
« no previous file with comments | « chrome/common/extensions/extension.h ('k') | chrome/common/extensions/extension_constants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698