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

Unified Diff: chrome/common/extensions/api/extension_api.json

Issue 7187023: Adding an experimental app notification API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixing clang errors Created 9 years, 6 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/chrome_browser.gypi ('k') | chrome/common/extensions/docs/experimental.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/api/extension_api.json
diff --git a/chrome/common/extensions/api/extension_api.json b/chrome/common/extensions/api/extension_api.json
index d507be19a632f916dd739361dde37adda10d8275..50b97f2abe58689b86d0305d474a642eefd37763 100644
--- a/chrome/common/extensions/api/extension_api.json
+++ b/chrome/common/extensions/api/extension_api.json
@@ -6170,5 +6170,110 @@
]
}
]
+ },
+ {
+ "namespace":"experimental.app",
+ "functions": [
+ {
+ "name": "notify",
+ "type": "function",
+ "description": "Creates a notification from this app.",
+ "parameters": [
+ {
+ "type": "object",
+ "name": "details",
+ "properties": {
+ "passive": {
+ "type": "boolean",
+ "optional": "true",
+ "description": "Whether the notification should be passive (true) or active (false). The default value is true."
+ },
+ "title": {
+ "type": "string",
+ "optional": true,
+ "description": "The title of the notification."
+ },
+ "bodyText": {
+ "type": "string",
+ "optional": true,
+ "description": "The text content of the notification."
+ },
+ "linkUrl": {
+ "type": "string",
+ "optional": true,
+ "description": "The URL for an optional link to show along with the notification. If you specify a linkUrl, you must also specify a value for linkText."
+ },
+ "linkText": {
+ "type": "string",
+ "optional": true,
+ "description": "If a linkUrl is provided, this is required and will be used as the linkified text. It should be relatively short."
+ },
+ "iconData": {
+ "type": "object",
+ "isInstanceOf": "ImageData",
+ "optional": true,
+ "properties": {},
+ "additionalProperties": { "type": "any" },
+ "description": "Pixel data for an image to use as the icon for this notification. Must be an ImageData object (for example, from a canvas element)."
+ }
+ }
+ },
+ {
+ "type": "function",
+ "name": "callback",
+ "optional": true,
+ "parameters": [],
+ "description": "A callback when the function is complete. Any errors will be reported in <a href='extension.html#property-lastError'>chrome.extension.lastError</a>."
+ }
+ ]
+ },
+ {
+ "name": "clearAllNotifications",
+ "type": "function",
+ "description": "Clears all previously sent notifications.",
+ "parameters": [
+ {
+ "type": "function",
+ "name": "callback",
+ "optional": true,
+ "description": "A callback when the function is complete. Any errors will be reported in <a href='extension.html#property-lastError'>chrome.extension.lastError</a>."
+ }
+ ]
+ },
+ {
+ "name": "setLaunchIcon",
+ "type": "function",
+ "parameters": [
+ {
+ "type": "object",
+ "name": "iconData",
+ "isInstanceOf": "ImageData",
+ "optional": true,
+ "properties": {},
+ "additionalProperties": { "type": "any" },
+ "description": "Pixel data for an image to replace the launch icon on the New Tab Page. Must be an ImageData object (for example, from a canvas element). See http://code.google.com/chrome/webstore/docs/images.html for more details."
+ },
+ {
+ "type": "function",
+ "name": "callback",
+ "optional": true,
+ "description": "A callback when the function is complete. Any errors will be reported in <a href='extension.html#property-lastError'>chrome.extension.lastError</a>."
+ }
+ ]
+ },
+ {
+ "name": "resetLaunchIcon",
+ "type": "function",
+ "description": "Resets the app's launch icon to its default value as specified in the manifest.json file.",
+ "parameters": [
+ {
+ "type": "function",
+ "name": "callback",
+ "optional": true,
+ "description": "A callback when the function is complete. Any errors will be reported in <a href='extension.html#property-lastError'>chrome.extension.lastError</a>."
+ }
+ ]
+ }
+ ]
}
]
« no previous file with comments | « chrome/chrome_browser.gypi ('k') | chrome/common/extensions/docs/experimental.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698