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

Unified Diff: extensions/common/api/idle.json

Issue 1055673002: [Extensions API] Remove inline enums (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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
Index: extensions/common/api/idle.json
diff --git a/extensions/common/api/idle.json b/extensions/common/api/idle.json
index 153e931c4d0b9054aa2762adaa46a3527c22ac6c..43a9d071b6a01b3ae72c487b3738805c8be6d528 100644
--- a/extensions/common/api/idle.json
+++ b/extensions/common/api/idle.json
@@ -6,7 +6,13 @@
{
"namespace": "idle",
"description": "Use the <code>chrome.idle</code> API to detect when the machine's idle state changes.",
- "types": [],
+ "types": [
+ {
+ "id": "IdleState",
+ "type": "string",
+ "enum": ["active", "idle", "locked"]
+ }
+ ],
"functions": [
{
"name": "queryState",
@@ -25,8 +31,7 @@
"parameters": [
{
"name": "newState",
- "type": "string",
- "enum": ["active", "idle", "locked"]
+ "$ref": "IdleState"
}
]
}
@@ -54,8 +59,7 @@
"parameters": [
{
"name": "newState",
- "type": "string",
- "enum": ["active", "idle", "locked"]
+ "$ref": "IdleState"
}
]
}

Powered by Google App Engine
This is Rietveld 408576698