OLD | NEW |
1 [ | 1 [ |
2 { | 2 { |
3 "namespace": "extension", | 3 "namespace": "extension", |
4 "unprivileged": true, | 4 "unprivileged": true, |
5 "types": [ | 5 "types": [ |
6 { | 6 { |
7 "id": "MessageSender", | 7 "id": "MessageSender", |
8 "type": "object", | 8 "type": "object", |
9 "description": "An object containing information about the script contex
t that sent a message or request.", | 9 "description": "An object containing information about the script contex
t that sent a message or request.", |
10 "properties": { | 10 "properties": { |
(...skipping 8052 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8063 "name": "result", | 8063 "name": "result", |
8064 "type": "string", | 8064 "type": "string", |
8065 "description": "A string result code. The value is non-empty on
success only in tests.", | 8065 "description": "A string result code. The value is non-empty on
success only in tests.", |
8066 "optional": "true" | 8066 "optional": "true" |
8067 } | 8067 } |
8068 ] | 8068 ] |
8069 } | 8069 } |
8070 ] | 8070 ] |
8071 } | 8071 } |
8072 ] | 8072 ] |
| 8073 }, |
| 8074 { |
| 8075 "namespace": "experimental.offscreenTabs", |
| 8076 "types": [ |
| 8077 { |
| 8078 "id": "OffscreenTab", |
| 8079 "type": "object", |
| 8080 "properties": { |
| 8081 "id": { |
| 8082 "type": "integer", |
| 8083 "minimum": 0, |
| 8084 "description": "The ID of the offscreen tab. Tab IDs are unique with
in a browser session." |
| 8085 }, |
| 8086 "url": { |
| 8087 "type": |
| 8088 "string", |
| 8089 "description": "URL of the offscreen tab." |
| 8090 }, |
| 8091 "width": { |
| 8092 "type": "integer", |
| 8093 "minimum": 0, |
| 8094 "description": "Width of the window." |
| 8095 }, |
| 8096 "height": { |
| 8097 "type": "integer", |
| 8098 "minimum": 0, |
| 8099 "description": "Height of the window." |
| 8100 } |
| 8101 } |
| 8102 } |
| 8103 ], |
| 8104 "functions": [ |
| 8105 { |
| 8106 "name": "create", |
| 8107 "type": "function", |
| 8108 "description": "Creates a new offscreen tab.", |
| 8109 "parameters": [ |
| 8110 { |
| 8111 "name": "createProperties", |
| 8112 "type": "object", |
| 8113 "properties": { |
| 8114 "url": { |
| 8115 "type": "string", |
| 8116 "description": "The URL to navigate the offscreen tab to initial
ly. Fully-qualified URLs must include a scheme (i.e. 'http://www.google.com', no
t 'www.google.com'). Relative URLs will be relative to the current page within t
he extension." |
| 8117 }, |
| 8118 "width": { |
| 8119 "type": "integer", |
| 8120 "optional": true, |
| 8121 "minimum": 0, |
| 8122 "description": "Width of the offscreen tab. Defaults to width of
the current tab." |
| 8123 }, |
| 8124 "height": { |
| 8125 "type": "integer", |
| 8126 "optional": true, |
| 8127 "minimum": 0, |
| 8128 "description": "Height of the offscreen tab. Defaults to height
of the current tab." |
| 8129 } |
| 8130 } |
| 8131 }, |
| 8132 { |
| 8133 "name": "callback", |
| 8134 "type": "function", |
| 8135 "optional": true, |
| 8136 "parameters": [ |
| 8137 { |
| 8138 "name": "offscreenTab", |
| 8139 "$ref": "OffscreenTab", |
| 8140 "optional": true, |
| 8141 "description": "Details of the offscreen tab." |
| 8142 } |
| 8143 ] |
| 8144 } |
| 8145 ] |
| 8146 }, |
| 8147 { |
| 8148 "name": "get", |
| 8149 "type": "function", |
| 8150 "description": "Gets details about the specified offscreen tab.", |
| 8151 "parameters": [ |
| 8152 { |
| 8153 "name": "offscreenTabId", |
| 8154 "type": "integer", |
| 8155 "minimum": 0, |
| 8156 "description": "ID of the offscreen tab." |
| 8157 }, |
| 8158 { |
| 8159 "name": "callback", |
| 8160 "type": "function", |
| 8161 "parameters": [ |
| 8162 { |
| 8163 "name": "offscreenTab", |
| 8164 "$ref": "OffscreenTab", |
| 8165 "description": "Details of the offscreen tab." |
| 8166 } |
| 8167 ] |
| 8168 } |
| 8169 ] |
| 8170 }, |
| 8171 { |
| 8172 "name": "getAll", |
| 8173 "type": "function", |
| 8174 "description": "Gets an array of all offscreen tabs.", |
| 8175 "parameters": [ |
| 8176 { |
| 8177 "name": "callback", |
| 8178 "type": "function", |
| 8179 "parameters": [ |
| 8180 { |
| 8181 "name": "offscreenTabs", |
| 8182 "type": "array", |
| 8183 "items": { |
| 8184 "$ref": "OffscreenTab" |
| 8185 } |
| 8186 } |
| 8187 ] |
| 8188 } |
| 8189 ] |
| 8190 }, |
| 8191 { |
| 8192 "name": "remove", |
| 8193 "type": "function", |
| 8194 "description": "Removes an offscreen tab.", |
| 8195 "parameters": [ |
| 8196 { |
| 8197 "name": "offscreenTabId", |
| 8198 "type": "integer", |
| 8199 "minimum": 0, |
| 8200 "description": "ID of the offscreen tab." |
| 8201 }, |
| 8202 { |
| 8203 "name": "callback", |
| 8204 "type": "function", |
| 8205 "optional": true |
| 8206 } |
| 8207 ] |
| 8208 }, |
| 8209 { |
| 8210 "name": "sendMouseEvent", |
| 8211 "type": "function", |
| 8212 "description": "Dispatches a mouse event in the offscreen tab.", |
| 8213 "parameters": [ |
| 8214 { |
| 8215 "name": "offscreenTabId", |
| 8216 "type": "integer", |
| 8217 "minimum": 0, |
| 8218 "description": "ID of the offscreen tab." |
| 8219 }, |
| 8220 { |
| 8221 "name": "mouseEvent", |
| 8222 "type": "any", |
| 8223 "description": "A JavaScript MouseEvent object. Supported event type
s: <i>mousedown</i>, <i>mouseup</i>, <i>click</i>, <i>mousemove</i>, <i>mousewhe
el</i>." |
| 8224 }, |
| 8225 { |
| 8226 "name": "x", |
| 8227 "type": "integer", |
| 8228 "optional": true, |
| 8229 "minimum": 0, |
| 8230 "description": "X position of where the mouse event should be dispat
ched on the offscreen web page. Not required in the case of a mousewheel event." |
| 8231 }, |
| 8232 { |
| 8233 "name": "y", |
| 8234 "type": "integer", |
| 8235 "optional": true, |
| 8236 "minimum": 0, |
| 8237 "description": "Y position of where the mouse event should be dispat
ched on the offscreen web page. Not required in the case of a mousewheel event." |
| 8238 }, |
| 8239 { |
| 8240 "name": "callback", |
| 8241 "type": "function", |
| 8242 "optional": true, |
| 8243 "parameters": [ |
| 8244 { |
| 8245 "name": "offscreenTab", |
| 8246 "$ref": "OffscreenTab", |
| 8247 "description": "Details of the offscreen tab." |
| 8248 } |
| 8249 ] |
| 8250 } |
| 8251 ] |
| 8252 }, |
| 8253 { |
| 8254 "name": "sendKeyboardEvent", |
| 8255 "type": "function", |
| 8256 "description": "Dispatches a keyboard event in the offscreen tab.", |
| 8257 "parameters": [ |
| 8258 { |
| 8259 "name": "offscreenTabId", |
| 8260 "type": "integer", |
| 8261 "minimum": 0, |
| 8262 "description": "ID of the offscreen tab." |
| 8263 }, |
| 8264 { |
| 8265 "name": "keyboardEvent", |
| 8266 "type": "any", |
| 8267 "description": "A JavaScript KeyboardEvent object. Supported event t
ypes: <i>keydown</i>, <i>keyup</i>, <i>keypress</i>. Note, only <i>keypress</i>
produces a visible result on screen." |
| 8268 }, |
| 8269 { |
| 8270 "name": "callback", |
| 8271 "type": "function", |
| 8272 "optional": true, |
| 8273 "parameters": [ |
| 8274 { |
| 8275 "name": "offscreenTab", |
| 8276 "$ref": "OffscreenTab", |
| 8277 "description": "Details of the offscreen tab." |
| 8278 } |
| 8279 ] |
| 8280 } |
| 8281 ] |
| 8282 }, |
| 8283 { |
| 8284 "name": "toDataUrl", |
| 8285 "type": "function", |
| 8286 "description": "Captures the visible area of an offscreen tab. ", |
| 8287 "parameters": [ |
| 8288 { |
| 8289 "name": "offscreenTabId", |
| 8290 "type": "integer", |
| 8291 "minimum": 0, |
| 8292 "description": "The ID of the offscreen tab." |
| 8293 }, |
| 8294 { |
| 8295 "name": "options", |
| 8296 "type": "object", |
| 8297 "optional": true, |
| 8298 "description": "Set parameters of image capture, such as the format
of the resulting image.", |
| 8299 "properties": { |
| 8300 "format": { |
| 8301 "type": "string", |
| 8302 "optional": true, |
| 8303 "enum": ["jpeg", "png"], |
| 8304 "description": "The format of the resulting image. Default is jp
eg." |
| 8305 }, |
| 8306 "quality": { |
| 8307 "type": "integer", |
| 8308 "optional": true, |
| 8309 "minimum": 0, |
| 8310 "maximum": 100, |
| 8311 "description": "When format is 'jpeg', controls the quality of t
he resulting image. This value is ignored for PNG images. As quality is decrease
d, the resulting image will have more visual artifacts, and the number of bytes
needed to store it will decrease." |
| 8312 } |
| 8313 } |
| 8314 }, |
| 8315 { |
| 8316 "name": "callback", |
| 8317 "type": "function", |
| 8318 "parameters": [ |
| 8319 { |
| 8320 "name": "dataUrl", |
| 8321 "type": "string", |
| 8322 "description": "A data URL which encodes an image of the visible
area of the captured offscreen tab. May be assigned to the 'src' property of an
HTML Image element or WebGL texture source for display." |
| 8323 } |
| 8324 ] |
| 8325 } |
| 8326 ] |
| 8327 }, |
| 8328 { |
| 8329 "name": "update", |
| 8330 "type": "function", |
| 8331 "description": "Modifies the properties of an offscreen tab. Properties
that are not specified in updateProperties are not modified.", |
| 8332 "parameters": [ |
| 8333 { |
| 8334 "name": "offscreenTabId", |
| 8335 "type": "integer", |
| 8336 "minimum": 0, |
| 8337 "description": "The ID of the offscreen tab." |
| 8338 }, |
| 8339 { |
| 8340 "name": "updateProperties", |
| 8341 "type": "object", |
| 8342 "properties": { |
| 8343 "url": { |
| 8344 "type": "string", |
| 8345 "optional": true, |
| 8346 "description": "The URL the offscreen tab is displaying." |
| 8347 }, |
| 8348 "width": { |
| 8349 "type": "integer", |
| 8350 "optional": true, |
| 8351 "description": "Width of the window." |
| 8352 }, |
| 8353 "height": { |
| 8354 "type": "integer", |
| 8355 "optional": true, |
| 8356 "description": "Height of the window." |
| 8357 } |
| 8358 } |
| 8359 }, |
| 8360 { |
| 8361 "name": "callback", |
| 8362 "type": "function", |
| 8363 "optional": true, |
| 8364 "parameters": [ |
| 8365 { |
| 8366 "name": "offscreenTab", |
| 8367 "$ref": "OffscreenTab", |
| 8368 "description": "Details of the offscreen tab." |
| 8369 } |
| 8370 ] |
| 8371 } |
| 8372 ] |
| 8373 } |
| 8374 ], |
| 8375 "events": [ |
| 8376 { |
| 8377 "name": "onCreated", |
| 8378 "type": "function", |
| 8379 "description": "NOT IMPLEMENTED YET. Fires when an offscreen tab is crea
ted. Note that the offscreen tab's data URL may not be set at the time this even
t fires, but you can listen to onUpdated events to be notified when a URL is set
.", |
| 8380 "parameters": [ |
| 8381 { |
| 8382 "name": "offscreenTab", |
| 8383 "$ref": "OffscreenTab", |
| 8384 "description": "Details of the offscreen tab." |
| 8385 } |
| 8386 ] |
| 8387 }, |
| 8388 { |
| 8389 "name": "onUpdated", |
| 8390 "type": "function", |
| 8391 "description": "NOT IMPLEMENTED YET. Fires when an offscreen tab is upda
ted. ", |
| 8392 "parameters": [ |
| 8393 { |
| 8394 "name": "offscreenTabId", |
| 8395 "type": "integer", |
| 8396 "minimum": 0, |
| 8397 "description": "ID of the updated offscreen tab" |
| 8398 }, |
| 8399 { |
| 8400 "name": "changeInfo", |
| 8401 "type": "object", |
| 8402 "description": "Lists the changes to the state of the offscreen tab
that was updated.", |
| 8403 "properties": { |
| 8404 "dataUrl": { |
| 8405 "type": "boolean", |
| 8406 "optional": true, |
| 8407 "description": "Whether the dataUrl of the offscreen tab has cha
nged. The new dataUrl can be obtained via the toDataUrl method." |
| 8408 }, |
| 8409 "url": { |
| 8410 "type": "string", |
| 8411 "optional": true, |
| 8412 "description": "The offscreen tab\u2019s URL if it has changed." |
| 8413 } |
| 8414 } |
| 8415 }, |
| 8416 { |
| 8417 "name": "offscreenTab", |
| 8418 "$ref": "OffscreenTab", |
| 8419 "description": "Details of the offscreen tab." |
| 8420 } |
| 8421 ] |
| 8422 } |
| 8423 ] |
8073 } | 8424 } |
8074 ] | 8425 ] |
OLD | NEW |