OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 [ | |
6 { | |
7 "namespace": "experimental.mediaGalleries", | |
8 "functions": [ | |
9 { | |
10 "name": "getMediaFileSystems", | |
11 "type": "function", | |
12 "description": "Get the media galleries configured in this user agent. I
f none are configured or available, the callback will receive an empty array.", | |
13 "parameters": [ | |
14 { | |
15 "type": "function", | |
16 "name": "callback", | |
17 "parameters": [ | |
18 { | |
19 "name": "mediaFileSystems", | |
20 "type": "array", | |
21 // TODO(vandebo) Specify the item type with isInstanceOf when | |
22 // http://crbug.com/119372 is resolved. | |
23 "items": { "type": "object"} | |
24 } | |
25 ] | |
26 } | |
27 ] | |
28 }, | |
29 { | |
30 "name": "openMediaGalleryManager", | |
31 "type": "function", | |
32 "description": "The user can configure which directories on their comput
er are exposed as media galleries. Calling this function will cause the UI which
configures media galleris to be visible in the current tab.", | |
33 "parameters": [] | |
34 }, | |
35 { | |
36 "name": "extractEmbeddedThumbnails", | |
37 "type": "function", | |
38 "description": "Get any thumbnails contained in the passed media file. T
he resulting directory reader refers to a virtual directory that can not be navi
gated to. If there are no thumbnails in the passed file entry, the virtual direc
tory will have no entries.", | |
39 "parameters": [ | |
40 { | |
41 // TODO(vandebo) Make this a non-optional FileEntry when | |
42 // http://crbug.com/119372 is resolved. | |
43 "type": "object", | |
44 "optional": true, | |
45 "name": "mediaFile" | |
46 } | |
47 ], | |
48 "returns": { | |
49 "type": "object", | |
50 "optional": true | |
51 } | |
52 }, | |
53 { | |
54 "name": "assembleMediaFile", | |
55 "type": "function", | |
56 "description": "Create a new MediaFile setting the metadata in the Blob
to the supplied values, overriding any existing metadata in the media file. If u
ser agent does not recognize the Blob as a supported file format, it will return
null in the callback.", | |
57 // TODO(vandebo) Remove allowAmbiguousOptionalArguments when | |
58 // http://crbug.com/119372 is resolved. | |
59 "allowAmbiguousOptionalArguments": true, | |
60 "parameters": [ | |
61 { | |
62 // TODO(vandebo) Make this a non-optional Blob when | |
63 // http://crbug.com/119372 is resolved. | |
64 "type": "object", | |
65 "optional": true, | |
66 "name": "mediaFileContents" | |
67 }, | |
68 { | |
69 // TODO(vandebo) Make this a non-optional Metafile when | |
70 // http://crbug.com/119372 is resolved. | |
71 "type": "object", | |
72 "optional": true, | |
73 "name": "metadata" | |
74 }, | |
75 { | |
76 "type": "function", | |
77 "name": "callback", | |
78 "parameters": [ | |
79 { | |
80 "name": "mediaFile", | |
81 // TODO(vandebo) Make this an optional Blob when | |
82 // http://crbug.com/119372 is resolved. | |
83 "type": "object", | |
84 "optional": true | |
85 } | |
86 ] | |
87 } | |
88 ] | |
89 } | |
90 ] | |
91 } | |
92 ] | |
OLD | NEW |