Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 [ | 5 [ |
| 6 { | 6 { |
| 7 "namespace": "runtime", | 7 "namespace": "runtime", |
| 8 "documentation_permissions_required": ["runtime"], | 8 "documentation_permissions_required": ["runtime"], |
| 9 "types": [ | 9 "types": [ |
| 10 { | 10 { |
| (...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 401 "parameters": [ | 401 "parameters": [ |
| 402 {"name": "message", "type": "any", "description": "The message sent by the calling script."}, | 402 {"name": "message", "type": "any", "description": "The message sent by the calling script."}, |
| 403 {"name": "sender", "$ref": "MessageSender" }, | 403 {"name": "sender", "$ref": "MessageSender" }, |
| 404 {"name": "sendResponse", "type": "function", "description": "Function to call (at most once) when you have a response. The argument should be any JSON -ifiable object. If you have more than one <code>onMessage</code> listener in th e same document, then only one may send a response. This function becomes invali d when the event listener returns, unless you return true from the event listene r to indicate you wish to send a response asynchronously (this will keep the mes sage channel open to the other end until <code>sendResponse</code> is called)." } | 404 {"name": "sendResponse", "type": "function", "description": "Function to call (at most once) when you have a response. The argument should be any JSON -ifiable object. If you have more than one <code>onMessage</code> listener in th e same document, then only one may send a response. This function becomes invali d when the event listener returns, unless you return true from the event listene r to indicate you wish to send a response asynchronously (this will keep the mes sage channel open to the other end until <code>sendResponse</code> is called)." } |
| 405 ], | 405 ], |
| 406 "returns": { | 406 "returns": { |
| 407 "type": "boolean", | 407 "type": "boolean", |
| 408 "optional": "true", | 408 "optional": "true", |
| 409 "description": "Return true from the event listener if you wish to cal l <code>sendResponse</code> after the event listener returns." | 409 "description": "Return true from the event listener if you wish to cal l <code>sendResponse</code> after the event listener returns." |
| 410 } | 410 } |
| 411 }, | |
| 412 { | |
| 413 "name": "onRestartRequired", | |
| 414 "type": "function", | |
| 415 "description": "Fired when an app needs to be restarted. The app should close all its windows at its earliest convenient time to let the restart to happ en. If the app does nothing, a restart will be enforced after a 24-hour grace pe riod has passed. Currently, this event is only fired for Chrome OS kiosk apps.", | |
|
bartfab (slow)
2013/06/21 18:18:13
Nit: "the app needs to be restarted" is not quite
xiyuan
2013/06/21 18:33:18
Done.
| |
| 416 "parameters": [ | |
| 417 { | |
| 418 "type": "string", | |
| 419 "name": "reason", | |
| 420 "description": "The reason that the event is being dispatched.", | |
| 421 "enum": ["app_update", "os_update", "periodic"] | |
| 422 } | |
| 423 ] | |
| 411 } | 424 } |
| 412 | |
| 413 | |
| 414 | |
| 415 ] | 425 ] |
| 416 } | 426 } |
| 417 ] | 427 ] |
| OLD | NEW |