Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / extensions / common / api / guest_view_internal.json
blob90c5d4e7b0e81a7f8106c2c3cb767de61473856d
1 // Copyright 2014 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.
6   {
7     "namespace": "guestViewInternal",
8     "compiler_options": {
9       "implemented_in": "extensions/browser/api/guest_view/guest_view_internal_api.h"
10     },
11     "description": "none",
12     "types": [
13       {
14         "id": "Size",
15         "type": "object",
16         "properties": {
17           "width": {
18             "type": "integer"
19           },
20           "height": {
21             "type": "integer"
22           }
23         }
24       },
25       {
26         "id": "SizeParams",
27         "type": "object",
28         "description": "Size parameters.",
29         "properties": {
30           "enableAutoSize": {
31             "type": "boolean",
32             "optional": true
33           },
34           "min": {
35             "$ref": "Size",
36             "optional": true
37           },
38           "max": {
39             "$ref": "Size",
40             "optional": true
41           },
42           "normal": {
43             "$ref": "Size",
44             "optional": true
45           }
46         }
47       }
48     ],
49     "functions": [
50       {
51         "name": "createGuest",
52         "type": "function",
53         "parameters": [
54           {
55             "type": "string",
56             "name": "viewType",
57             "nodoc": true
58           },
59           {
60             "type": "object",
61             "name": "createParams",
62             "additionalProperties": {"type": "any"}
63           },
64           {
65             "type": "function",
66             "name": "callback",
67             "parameters": [
68               {
69                 "type": "object",
70                 "name": "returnParams",
71                 "additionalProperties": {"type": "any"}
72               }
73             ]
74           }
75         ]
76       },
77       {
78         "name": "destroyGuest",
79         "type": "function",
80         "parameters": [
81           {
82             "type": "integer",
83             "name": "instanceId"
84           },
85           {
86             "type": "function",
87             "name": "callback",
88             "parameters": [],
89             "optional": true
90           }
91         ]
92       },
93       {
94         "name": "setSize",
95         "type": "function",
96         "parameters": [
97           {
98             "type": "integer",
99             "name": "instanceId",
100             "description": "The instance ID of the guest <webview> process. This not exposed to developers through the API."
101           },
102           {
103             "$ref": "SizeParams",
104             "name": "params"
105           },
106           {
107             "type": "function",
108             "name": "callback",
109             "parameters": [],
110             "optional": true
111           }
112         ]
113       }
114     ]
115   }