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": "contextMenus", | 7 "namespace": "contextMenus", |
8 "dependencies": [ "tabs" ], | 8 "dependencies": [ "tabs" ], |
9 "types": [ | 9 "types": [ |
10 { | 10 { |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 "optional": true, | 71 "optional": true, |
72 "description": "A flag indicating the state of a checkbox or radio i
tem after it is clicked." | 72 "description": "A flag indicating the state of a checkbox or radio i
tem after it is clicked." |
73 } | 73 } |
74 } | 74 } |
75 } | 75 } |
76 ], | 76 ], |
77 "functions": [ | 77 "functions": [ |
78 { | 78 { |
79 "name": "create", | 79 "name": "create", |
80 "type": "function", | 80 "type": "function", |
81 "description": "Creates a new context menu item. Note that if an error o
ccurs during creation, you may not find out until the creation callback fires (t
he details will be in chrome.extension.lastError).", | 81 "description": "Creates a new context menu item. Note that if an error o
ccurs during creation, you may not find out until the creation callback fires (t
he details will be in chrome.runtime.lastError).", |
82 "returns": { | 82 "returns": { |
83 "choices": [ | 83 "choices": [ |
84 { "type": "integer" }, | 84 { "type": "integer" }, |
85 { "type": "string" } | 85 { "type": "string" } |
86 ], | 86 ], |
87 "description": "The ID of the newly created item." | 87 "description": "The ID of the newly created item." |
88 }, | 88 }, |
89 "parameters": [ | 89 "parameters": [ |
90 { | 90 { |
91 "type": "object", | 91 "type": "object", |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 "type": "boolean", | 163 "type": "boolean", |
164 "optional": true, | 164 "optional": true, |
165 "description": "Whether this context menu item is enabled or dis
abled. Defaults to true." | 165 "description": "Whether this context menu item is enabled or dis
abled. Defaults to true." |
166 } | 166 } |
167 } | 167 } |
168 }, | 168 }, |
169 { | 169 { |
170 "type": "function", | 170 "type": "function", |
171 "name": "callback", | 171 "name": "callback", |
172 "optional": true, | 172 "optional": true, |
173 "description": "Called when the item has been created in the browser
. If there were any problems creating the item, details will be available in chr
ome.extension.lastError.", | 173 "description": "Called when the item has been created in the browser
. If there were any problems creating the item, details will be available in chr
ome.runtime.lastError.", |
174 "parameters": [] | 174 "parameters": [] |
175 } | 175 } |
176 ] | 176 ] |
177 }, | 177 }, |
178 { | 178 { |
179 "name": "update", | 179 "name": "update", |
180 "type": "function", | 180 "type": "function", |
181 "description": "Updates a previously created context menu item.", | 181 "description": "Updates a previously created context menu item.", |
182 "parameters": [ | 182 "parameters": [ |
183 { | 183 { |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
304 "name": "tab", | 304 "name": "tab", |
305 "$ref": "tabs.Tab", | 305 "$ref": "tabs.Tab", |
306 "description": "The details of the tab where the click took place. I
f the click did not take place in a tab, this parameter will be missing.", | 306 "description": "The details of the tab where the click took place. I
f the click did not take place in a tab, this parameter will be missing.", |
307 "optional": true | 307 "optional": true |
308 } | 308 } |
309 ] | 309 ] |
310 } | 310 } |
311 ] | 311 ] |
312 } | 312 } |
313 ] | 313 ] |
OLD | NEW |