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

Unified Diff: content/public/common/manifest.h

Issue 1235883007: manifest: add theme_color value to the manifest (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add comments Created 5 years, 5 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 | « content/common/manifest_manager_messages.h ('k') | content/public/common/manifest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/common/manifest.h
diff --git a/content/public/common/manifest.h b/content/public/common/manifest.h
index 43bef5bee75f500d1233d3e80ba23a4a22c8e9c9..c1eba7c2111d532035be0e2c4c4521029123aee3 100644
--- a/content/public/common/manifest.h
+++ b/content/public/common/manifest.h
@@ -112,6 +112,13 @@ struct CONTENT_EXPORT Manifest {
// or there is a parsing failure.
bool prefer_related_applications;
+ // This is a 64 bit integer because we need to represent an error state. The
+ // color itself should only be 32 bits long if the value is not
+ // kInvalidOrMissingThemeColor and can be safely cast to SkColor if is valid.
+ // Set to kInvalidOrMissingThemeColor if parsing failed or field is not
+ // present.
+ int64_t theme_color;
+
// This is a proprietary extension of the web Manifest, double-check that it
// is okay to use this entry.
// Null if parsing failed or the field was not present.
@@ -121,6 +128,9 @@ struct CONTENT_EXPORT Manifest {
// IPC. The renderer process should truncate the strings before sending the
// Manifest and the browser process must do the same when receiving it.
static const size_t kMaxIPCStringLength;
+
+ // Constant representing an invalid theme color. Set to -1.
+ static const int64_t kInvalidOrMissingThemeColor;
};
} // namespace content
« no previous file with comments | « content/common/manifest_manager_messages.h ('k') | content/public/common/manifest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698