| 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":"webstorePrivate", |
| 8 "nodoc": "true", |
| 9 "functions": [ |
| 10 { |
| 11 "name": "install", |
| 12 "description": "Installs the extension corresponding to the given id", |
| 13 "parameters": [ |
| 14 { |
| 15 "name": "expected_id", |
| 16 "type": "string", |
| 17 "description": "The id of the extension to install." |
| 18 }, |
| 19 { |
| 20 "name": "callback", |
| 21 "type": "function", |
| 22 "optional": "true", |
| 23 "parameters": [] |
| 24 } |
| 25 ] |
| 26 }, |
| 27 { |
| 28 "name": "installBundle", |
| 29 "description": "Initiates the install process for the given bundle of ex
tensions.", |
| 30 "parameters": [ |
| 31 { |
| 32 "name": "details", |
| 33 "description": "An array of extension details to be installed.", |
| 34 "type": "array", |
| 35 "items": { |
| 36 "type": "object", |
| 37 "properties": { |
| 38 "id": { |
| 39 "type": "string", |
| 40 "description": "The id of the extension to be installed.", |
| 41 "minLength": 32, |
| 42 "maxLength": 32 |
| 43 }, |
| 44 "manifest": { |
| 45 "type": "string", |
| 46 "description": "A string with the contents of the extension's
manifest.json file. During the install process, the browser will check that the
downloaded extension's manifest matches what was passed in here.", |
| 47 "minLength": 1 |
| 48 }, |
| 49 "localizedName": { |
| 50 "type": "string", |
| 51 "description": "A string to use instead of the raw value of th
e 'name' key from manifest.json." |
| 52 } |
| 53 } |
| 54 } |
| 55 }, |
| 56 { |
| 57 "name": "callback", |
| 58 "type": "function", |
| 59 "description": "Called when the install process completes. Upon fail
ures, chrome.runtime.lastError will be set to 'user_canceled' or 'unknown_error'
.", |
| 60 "optional": "true", |
| 61 "parameters": [] |
| 62 } |
| 63 ] |
| 64 }, |
| 65 { |
| 66 "name": "beginInstallWithManifest3", |
| 67 "description": "Initiates the install process for the given extension.", |
| 68 "parameters": [ |
| 69 { |
| 70 "name": "details", |
| 71 "type": "object", |
| 72 "properties": { |
| 73 "id": { |
| 74 "type": "string", |
| 75 "description": "The id of the extension to be installled.", |
| 76 "minLength": 32, |
| 77 "maxLength": 32 |
| 78 }, |
| 79 "manifest": { |
| 80 "type": "string", |
| 81 "description": "A string with the contents of the extension's ma
nifest.json file. During the install process, the browser will check that the do
wnloaded extension's manifest matches what was passed in here.", |
| 82 "minLength": 1 |
| 83 }, |
| 84 "iconUrl": { |
| 85 "type": "string", |
| 86 "optional": true, |
| 87 "desciption": "A URL for the image to display in the confirmatio
n dialog" |
| 88 }, |
| 89 "iconData": { |
| 90 "type": "string", |
| 91 "optional": true, |
| 92 "description": "An icon as a base64-encoded image, displayed in
a confirmation dialog." |
| 93 }, |
| 94 "localizedName": { |
| 95 "type": "string", |
| 96 "optional": true, |
| 97 "description": "A string to use instead of the raw value of the
'name' key from manifest.json." |
| 98 }, |
| 99 "locale": { |
| 100 "type": "string", |
| 101 "optional": true, |
| 102 "description": "The name of the locale used for generating local
izedName. This should be the name of one of the directories in the _locales fold
er of the extension, or the default_locale setting from the manifest." |
| 103 }, |
| 104 "appInstallBubble": { |
| 105 "type": "boolean", |
| 106 "optional": true, |
| 107 "description": "A flag to change the UI we show when an app is i
nstalled - a value of true means to show a bubble pointing at the new tab button
(instead of the default behavior of opening the new tab page and animating the
app icon)." |
| 108 } |
| 109 }, |
| 110 "additionalProperties": { "type": "any" } |
| 111 }, |
| 112 { |
| 113 "name": "callback", |
| 114 "type": "function", |
| 115 "description": "Called when the user has either accepted/rejected th
e dialog, or some error occurred (such as invalid manifest or icon image data)."
, |
| 116 "optional": "true", |
| 117 "parameters": [ |
| 118 { |
| 119 "name": "result", |
| 120 "type": "string", |
| 121 "description": "A string result code, which will be empty upon s
uccess. The possible values in the case of errors include 'unknown_error', 'user
_cancelled', 'manifest_error', 'icon_error', 'invalid_id', 'permission_denied',
and 'invalid_icon_url'." |
| 122 } |
| 123 ] |
| 124 } |
| 125 ] |
| 126 |
| 127 }, |
| 128 { |
| 129 "name": "completeInstall", |
| 130 "description": "", |
| 131 "parameters": [ |
| 132 { |
| 133 "name": "expected_id", |
| 134 "type": "string", |
| 135 "description": "The id of the extension to be installed. This should
match a previous call to beginInstallWithManifest3." |
| 136 }, |
| 137 { |
| 138 "name": "callback", |
| 139 "type": "function", |
| 140 "optional": "true", |
| 141 "parameters": [] |
| 142 } |
| 143 ] |
| 144 }, |
| 145 { |
| 146 "name": "getBrowserLogin", |
| 147 "description": "Returns the logged-in sync user login if there is one, o
r the empty string otherwise.", |
| 148 "parameters": [ |
| 149 { |
| 150 "name": "callback", |
| 151 "type": "function", |
| 152 "optional": "false", |
| 153 "parameters": [ |
| 154 { |
| 155 "name": "info", |
| 156 "type": "object", |
| 157 "properties": { |
| 158 "login": { "type": "string" } |
| 159 } |
| 160 } |
| 161 ] |
| 162 } |
| 163 ] |
| 164 }, |
| 165 { |
| 166 "name": "getStoreLogin", |
| 167 "description": "Returns the previous value set by setStoreLogin, or the
empty string if there is none.", |
| 168 "parameters": [ |
| 169 { |
| 170 "name": "callback", |
| 171 "type": "function", |
| 172 "optional": "false", |
| 173 "parameters": [ |
| 174 { "name": "login", "type": "string" } |
| 175 ] |
| 176 } |
| 177 ] |
| 178 }, |
| 179 { |
| 180 "name": "setStoreLogin", |
| 181 "description": "Sets a preference value with the store login.", |
| 182 "parameters": [ |
| 183 { "name": "login", "type": "string" }, |
| 184 { |
| 185 "name": "callback", |
| 186 "type": "function", |
| 187 "optional": "true", |
| 188 "parameters": [] |
| 189 } |
| 190 ] |
| 191 }, |
| 192 { |
| 193 "name": "getWebGLStatus", |
| 194 "description": "Invokes a callback that returns whether WebGL is blackli
sted or not.", |
| 195 "parameters": [ |
| 196 { |
| 197 "name": "callback", |
| 198 "type": "function", |
| 199 "optional": "false", |
| 200 "parameters": [ |
| 201 { |
| 202 "name": "webgl_status", |
| 203 "type": "string", |
| 204 "enum": ["webgl_allowed", "webgl_blocked"] |
| 205 } |
| 206 ] |
| 207 } |
| 208 ] |
| 209 } |
| 210 ] |
| 211 } |
| 212 ] |
| OLD | NEW |