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": "permissions", | 7 "namespace": "permissions", |
8 "description": "Use the <code>chrome.permissions</code> API to request <a hr ef=\"#manifest\">declared optional permissions</a> at run time rather than insta ll time, so users understand why the permissions are needed and grant only those that are necessary.", | 8 "description": "Use the <code>chrome.permissions</code> API to request <a hr ef=\"#manifest\">declared optional permissions</a> at run time rather than insta ll time, so users understand why the permissions are needed and grant only those that are necessary.", |
9 "types": [ | 9 "types": [ |
10 { | 10 { |
11 "id": "Permissions", | 11 "id": "Permissions", |
12 "type": "object", | 12 "type": "object", |
13 "properties": { | 13 "properties": { |
14 "permissions": { | 14 "permissions": { |
15 "type": "array", | 15 "type": "array", |
16 "items": {"type": "string"}, | 16 "items": {"type": "string"}, |
17 "optional": true, | 17 "optional": true, |
18 "description": "List of named permissions (does not include hosts or origins)." | 18 "description": "List of named permissions (does not include hosts or origins). Anything listed here must appear in the <code>optional_permissions</ code> list in the manifest." |
19 }, | 19 }, |
20 "origins": { | 20 "origins": { |
21 "type": "array", | 21 "type": "array", |
22 "items": {"type": "string"}, | 22 "items": {"type": "string"}, |
23 "optional": true, | 23 "optional": true, |
24 "description": "List of origin permissions." | 24 "description": "List of origin permissions. Anything listed here mus t be a subset of a host that appears in the <code>optional_permissions</code> li st in the manifest. e.g. if <code>http://*.example.com/</code> or <code>http://* /</code> appears in <code>optional_permissions</code>, you can request an origin of <code>http://help.example.com/</code>. Any path is ignored." |
not at google - send to devlin
2013/12/19 20:53:13
nit: For example not e.g.
not nit: double-check th
Jeffrey Yasskin
2013/12/19 21:32:50
Done.
not at google - send to devlin
2013/12/19 21:54:54
The API is badly named, it's not an origin (as you
| |
25 } | 25 } |
26 } | 26 } |
27 } | 27 } |
28 ], | 28 ], |
29 "events": [ | 29 "events": [ |
30 { | 30 { |
31 "name": "onAdded", | 31 "name": "onAdded", |
32 "type": "function", | 32 "type": "function", |
33 "description": "Fired when the extension acquires new permissions.", | 33 "description": "Fired when the extension acquires new permissions.", |
34 "parameters": [ | 34 "parameters": [ |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
135 "type": "boolean", | 135 "type": "boolean", |
136 "description": "True if the permissions were removed." | 136 "description": "True if the permissions were removed." |
137 } | 137 } |
138 ] | 138 ] |
139 } | 139 } |
140 ] | 140 ] |
141 } | 141 } |
142 ] | 142 ] |
143 } | 143 } |
144 ] | 144 ] |
OLD | NEW |