summaryrefslogtreecommitdiffstats
path: root/chrome/common/extensions/api
diff options
context:
space:
mode:
authorbrg@chromium.com <brg@chromium.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-16 00:19:34 +0000
committerbrg@chromium.com <brg@chromium.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-03-16 00:19:34 +0000
commitf5205419c04244f460891b8ff8e30d3793ffa507 (patch)
tree4becb4662d36d92050001eb65e624cffeec95c10 /chrome/common/extensions/api
parent5c7c98d536de7fb818b7f23ae52a92383072aa0d (diff)
downloadchromium_src-f5205419c04244f460891b8ff8e30d3793ffa507.zip
chromium_src-f5205419c04244f460891b8ff8e30d3793ffa507.tar.gz
chromium_src-f5205419c04244f460891b8ff8e30d3793ffa507.tar.bz2
Idle API for the extension system
Tests=ExtensionApiTest.Idle Bug=one Review URL: http://codereview.chromium.org/845005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@41661 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/extensions/api')
-rwxr-xr-xchrome/common/extensions/api/extension_api.json43
1 files changed, 43 insertions, 0 deletions
diff --git a/chrome/common/extensions/api/extension_api.json b/chrome/common/extensions/api/extension_api.json
index c0042c0..a65aac8 100755
--- a/chrome/common/extensions/api/extension_api.json
+++ b/chrome/common/extensions/api/extension_api.json
@@ -1825,6 +1825,49 @@
]
},
{
+ "namespace": "experimental.idle",
+ "nodoc": "true",
+ "types": [],
+ "functions": [
+ {
+ "name": "queryState",
+ "type": "function",
+ "description": "Returns the current state of the browser.",
+ "parameters": [
+ {
+ "name": "threshold",
+ "type": "integer",
+ "minimum": 15,
+ "description": "Threshold used to determine when a machine is in the idle state."
+ },
+ {
+ "name": "callback",
+ "type": "function",
+ "parameters": [
+ {
+ "type": "string",
+ "enum": ["active", "idle", "locked"]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "events": [
+ {
+ "name": "onStateChanged",
+ "type": "function",
+ "description": "Fired when the browser changes to an active state. Currently only reports the transition from idle to active.",
+ "parameters": [
+ {
+ "type": "string",
+ "enum": ["active"]
+ }
+ ]
+ }
+ ]
+ },
+ {
"namespace": "toolstrip",
"nodoc": true,
"types": [],