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

Side by Side Diff: extensions/common/api/runtime.json

Issue 305643011: Expose enums to extension bindings. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/renderer/resources/extensions/binding.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Note: Many of these functions and events are implemented by hand and should 5 // Note: Many of these functions and events are implemented by hand and should
6 // not elicit any code generation from the schema compiler. These items are 6 // not elicit any code generation from the schema compiler. These items are
7 // marked "nocompile." 7 // marked "nocompile."
8 [ 8 [
9 { 9 {
10 "namespace": "runtime", 10 "namespace": "runtime",
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 "type": "string", 55 "type": "string",
56 "enum": ["arm", "x86-32", "x86-64"], 56 "enum": ["arm", "x86-32", "x86-64"],
57 "description": "The machine's processor architecture." 57 "description": "The machine's processor architecture."
58 }, 58 },
59 "nacl_arch" : { 59 "nacl_arch" : {
60 "description": "The native client architecture. This may be differen t from arch on some platforms.", 60 "description": "The native client architecture. This may be differen t from arch on some platforms.",
61 "type": "string", 61 "type": "string",
62 "enum": ["arm", "x86-32", "x86-64"] 62 "enum": ["arm", "x86-32", "x86-64"]
63 } 63 }
64 } 64 }
65 },
66 {
67 "id": "UpdateCheckResult",
68 "type": "string",
69 "enum": ["throttled", "no_update", "update_available"],
70 "description": "Result of the update check."
65 } 71 }
66 ], 72 ],
67 "properties": { 73 "properties": {
68 "lastError": { 74 "lastError": {
69 "type": "object", 75 "type": "object",
70 "optional": true, 76 "optional": true,
71 "description": "This will be defined during an API method callback if th ere was an error", 77 "description": "This will be defined during an API method callback if th ere was an error",
72 "properties": { 78 "properties": {
73 "message": { 79 "message": {
74 "optional": true, 80 "optional": true,
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 "name": "requestUpdateCheck", 164 "name": "requestUpdateCheck",
159 "type": "function", 165 "type": "function",
160 "description": "Requests an update check for this app/extension.", 166 "description": "Requests an update check for this app/extension.",
161 "parameters": [ 167 "parameters": [
162 { 168 {
163 "type": "function", 169 "type": "function",
164 "name": "callback", 170 "name": "callback",
165 "parameters": [ 171 "parameters": [
166 { 172 {
167 "name": "status", 173 "name": "status",
168 "type": "string", 174 "$ref": "UpdateCheckResult"
169 "enum": ["throttled", "no_update", "update_available"],
170 "description": "Result of the update check."
171 }, 175 },
172 { 176 {
173 "name": "details", 177 "name": "details",
174 "type": "object", 178 "type": "object",
175 "optional": true, 179 "optional": true,
176 "properties": { 180 "properties": {
177 "version": { 181 "version": {
178 "type": "string", 182 "type": "string",
179 "description": "The version of the available update." 183 "description": "The version of the available update."
180 } 184 }
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
473 "type": "string", 477 "type": "string",
474 "name": "reason", 478 "name": "reason",
475 "description": "The reason that the event is being dispatched. 'app_ update' is used when the restart is needed because the application is updated to a newer version. 'os_update' is used when the restart is needed because the bro wser/OS is updated to a newer version. 'periodic' is used when the system runs f or more than the permitted uptime set in the enterprise policy.", 479 "description": "The reason that the event is being dispatched. 'app_ update' is used when the restart is needed because the application is updated to a newer version. 'os_update' is used when the restart is needed because the bro wser/OS is updated to a newer version. 'periodic' is used when the system runs f or more than the permitted uptime set in the enterprise policy.",
476 "enum": ["app_update", "os_update", "periodic"] 480 "enum": ["app_update", "os_update", "periodic"]
477 } 481 }
478 ] 482 ]
479 } 483 }
480 ] 484 ]
481 } 485 }
482 ] 486 ]
OLDNEW
« no previous file with comments | « chrome/renderer/resources/extensions/binding.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698