OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2009 The Closure Compiler Authors | 2 * Copyright 2009 The Closure Compiler Authors |
3 * | 3 * |
4 * Licensed under the Apache License, Version 2.0 (the "License"); | 4 * Licensed under the Apache License, Version 2.0 (the "License"); |
5 * you may not use this file except in compliance with the License. | 5 * you may not use this file except in compliance with the License. |
6 * You may obtain a copy of the License at | 6 * You may obtain a copy of the License at |
7 * | 7 * |
8 * http://www.apache.org/licenses/LICENSE-2.0 | 8 * http://www.apache.org/licenses/LICENSE-2.0 |
9 * | 9 * |
10 * Unless required by applicable law or agreed to in writing, software | 10 * Unless required by applicable law or agreed to in writing, software |
(...skipping 2312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2323 | 2323 |
2324 /** | 2324 /** |
2325 * @const | 2325 * @const |
2326 * @see https://developer.chrome.com/extensions/bookmarks.html | 2326 * @see https://developer.chrome.com/extensions/bookmarks.html |
2327 */ | 2327 */ |
2328 chrome.bookmarks = {}; | 2328 chrome.bookmarks = {}; |
2329 | 2329 |
2330 | 2330 |
2331 /** | 2331 /** |
2332 * @typedef {?{ | 2332 * @typedef {?{ |
2333 * pareintId: (string|undefined), | 2333 * parentId: (string|undefined), |
2334 * index: (number|undefined), | 2334 * index: (number|undefined), |
2335 * url: (string|undefined), | 2335 * url: (string|undefined), |
2336 * title: (string|undefined) | 2336 * title: (string|undefined) |
2337 * }} | 2337 * }} |
2338 * @see https://developer.chrome.com/extensions/bookmarks#method-create | 2338 * @see https://developer.chrome.com/extensions/bookmarks#method-create |
2339 */ | 2339 */ |
2340 chrome.bookmarks.CreateDetails; | 2340 chrome.bookmarks.CreateDetails; |
2341 | 2341 |
2342 | 2342 |
2343 /** | 2343 /** |
| 2344 * @typedef {?{ |
| 2345 * query: (string|undefined), |
| 2346 * url: (string|undefined), |
| 2347 * title: (string|undefined) |
| 2348 * }} |
| 2349 * @see https://developer.chrome.com/extensions/bookmarks#method-search |
| 2350 */ |
| 2351 chrome.bookmarks.SearchDetails; |
| 2352 |
| 2353 |
| 2354 /** |
2344 * @param {(string|Array.<string>)} idOrIdList | 2355 * @param {(string|Array.<string>)} idOrIdList |
2345 * @param {function(Array.<BookmarkTreeNode>): void} callback The | 2356 * @param {function(Array.<BookmarkTreeNode>): void} callback The |
2346 * callback function which accepts an array of BookmarkTreeNode. | 2357 * callback function which accepts an array of BookmarkTreeNode. |
2347 * @return {Array.<BookmarkTreeNode>} | 2358 * @return {Array.<BookmarkTreeNode>} |
2348 */ | 2359 */ |
2349 chrome.bookmarks.get = function(idOrIdList, callback) {}; | 2360 chrome.bookmarks.get = function(idOrIdList, callback) {}; |
2350 | 2361 |
2351 | 2362 |
2352 /** | 2363 /** |
2353 * @param {string} id | 2364 * @param {string} id |
(...skipping 24 matching lines...) Expand all Loading... |
2378 /** | 2389 /** |
2379 * @param {string} id The ID of the root of the subtree to retrieve. | 2390 * @param {string} id The ID of the root of the subtree to retrieve. |
2380 * @param {function(Array.<BookmarkTreeNode>): void} callback The | 2391 * @param {function(Array.<BookmarkTreeNode>): void} callback The |
2381 * callback function which accepts an array of BookmarkTreeNode. | 2392 * callback function which accepts an array of BookmarkTreeNode. |
2382 * @return {Array.<BookmarkTreeNode>} | 2393 * @return {Array.<BookmarkTreeNode>} |
2383 */ | 2394 */ |
2384 chrome.bookmarks.getSubTree = function(id, callback) {}; | 2395 chrome.bookmarks.getSubTree = function(id, callback) {}; |
2385 | 2396 |
2386 | 2397 |
2387 /** | 2398 /** |
2388 * @param {string} query | 2399 * @param {string|!chrome.bookmarks.SearchDetails} query |
2389 * @param {function(Array.<BookmarkTreeNode>): void} callback | 2400 * @param {function(Array.<BookmarkTreeNode>): void} callback |
2390 * @return {Array.<BookmarkTreeNode>} | 2401 * @return {Array.<BookmarkTreeNode>} |
2391 */ | 2402 */ |
2392 chrome.bookmarks.search = function(query, callback) {}; | 2403 chrome.bookmarks.search = function(query, callback) {}; |
2393 | 2404 |
2394 | 2405 |
2395 /** | 2406 /** |
2396 * @param {chrome.bookmarks.CreateDetails} bookmark | 2407 * @param {chrome.bookmarks.CreateDetails} bookmark |
2397 * @param {function(BookmarkTreeNode): void=} opt_callback The | 2408 * @param {function(BookmarkTreeNode): void=} opt_callback The |
2398 * callback function which accepts a BookmarkTreeNode object. | 2409 * callback function which accepts a BookmarkTreeNode object. |
(...skipping 792 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3191 chrome.history.onVisitRemoved; | 3202 chrome.history.onVisitRemoved; |
3192 | 3203 |
3193 | 3204 |
3194 /** @type {!ChromeEvent} */ | 3205 /** @type {!ChromeEvent} */ |
3195 chrome.history.onVisited; | 3206 chrome.history.onVisited; |
3196 | 3207 |
3197 | 3208 |
3198 /** | 3209 /** |
3199 * @const | 3210 * @const |
3200 * @see http://developer.chrome.com/apps/identity.html | 3211 * @see http://developer.chrome.com/apps/identity.html |
| 3212 * TODO: replace TokenDetails, InvalidTokenDetails and |
| 3213 * WebAuthFlowDetails with Object. |
3201 */ | 3214 */ |
3202 chrome.identity = {}; | 3215 chrome.identity = {}; |
3203 | 3216 |
3204 | 3217 |
3205 /** | 3218 /** |
3206 * @param {(chrome.identity.TokenDetails|function(string=): void)} | 3219 * @param {(chrome.identity.TokenDetails|function(string=): void)} |
3207 * detailsOrCallback Token options or a callback function if no options are | 3220 * detailsOrCallback Token options or a callback function if no options are |
3208 * specified. | 3221 * specified. |
3209 * @param {function(string=): void=} opt_callback A callback function if options | 3222 * @param {function(string=): void=} opt_callback A callback function if options |
3210 * are specified. | 3223 * are specified. |
(...skipping 20 matching lines...) Expand all Loading... |
3231 * @param {chrome.identity.WebAuthFlowDetails} details | 3244 * @param {chrome.identity.WebAuthFlowDetails} details |
3232 * @param {function(string=): void} callback | 3245 * @param {function(string=): void} callback |
3233 */ | 3246 */ |
3234 chrome.identity.launchWebAuthFlow = function(details, callback) {}; | 3247 chrome.identity.launchWebAuthFlow = function(details, callback) {}; |
3235 | 3248 |
3236 | 3249 |
3237 /** @typedef {{url: string, interactive: (boolean|undefined)}} */ | 3250 /** @typedef {{url: string, interactive: (boolean|undefined)}} */ |
3238 chrome.identity.WebAuthFlowDetails; | 3251 chrome.identity.WebAuthFlowDetails; |
3239 | 3252 |
3240 | 3253 |
| 3254 /** @param {!function(!Object=):void} callback */ |
| 3255 chrome.identity.getProfileUserInfo = function(callback) {}; |
| 3256 |
| 3257 |
3241 /** @type {!ChromeEvent} */ | 3258 /** @type {!ChromeEvent} */ |
3242 chrome.identity.onSignInChanged; | 3259 chrome.identity.onSignInChanged; |
3243 | 3260 |
3244 | 3261 |
3245 /** | 3262 /** |
3246 * @const | 3263 * @const |
3247 * @see https://developer.chrome.com/extensions/input.ime.html | 3264 * @see https://developer.chrome.com/extensions/input.ime.html |
3248 */ | 3265 */ |
3249 chrome.input = {}; | 3266 chrome.input = {}; |
3250 | 3267 |
(...skipping 2004 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5255 | 5272 |
5256 | 5273 |
5257 /** @type {string} */ | 5274 /** @type {string} */ |
5258 ChromeKeyboardEvent.prototype.type; | 5275 ChromeKeyboardEvent.prototype.type; |
5259 | 5276 |
5260 | 5277 |
5261 /** @type {string} */ | 5278 /** @type {string} */ |
5262 ChromeKeyboardEvent.prototype.requestId; | 5279 ChromeKeyboardEvent.prototype.requestId; |
5263 | 5280 |
5264 | 5281 |
| 5282 /** @type {string|undefined} */ |
| 5283 ChromeKeyboardEvent.prototype.extensionId; |
| 5284 |
| 5285 |
5265 /** @type {string} */ | 5286 /** @type {string} */ |
5266 ChromeKeyboardEvent.prototype.key; | 5287 ChromeKeyboardEvent.prototype.key; |
5267 | 5288 |
5268 | 5289 |
5269 /** @type {boolean} */ | 5290 /** @type {string} */ |
| 5291 ChromeKeyboardEvent.prototype.code; |
| 5292 |
| 5293 |
| 5294 /** @type {number|undefined} */ |
| 5295 ChromeKeyboardEvent.prototype.keyCode; |
| 5296 |
| 5297 |
| 5298 /** @type {boolean|undefined} */ |
5270 ChromeKeyboardEvent.prototype.altKey; | 5299 ChromeKeyboardEvent.prototype.altKey; |
5271 | 5300 |
5272 | 5301 |
5273 /** @type {boolean} */ | 5302 /** @type {boolean|undefined} */ |
5274 ChromeKeyboardEvent.prototype.ctrlKey; | 5303 ChromeKeyboardEvent.prototype.ctrlKey; |
5275 | 5304 |
5276 | 5305 |
5277 /** @type {boolean} */ | 5306 /** @type {boolean|undefined} */ |
5278 ChromeKeyboardEvent.prototype.shiftKey; | 5307 ChromeKeyboardEvent.prototype.shiftKey; |
5279 | 5308 |
5280 | 5309 |
| 5310 /** @type {boolean|undefined} */ |
| 5311 ChromeKeyboardEvent.prototype.capsLock; |
| 5312 |
| 5313 |
5281 | 5314 |
5282 /** | 5315 /** |
5283 * @see https://developer.chrome.com/extensions/input.ime.html#type-InputContext | 5316 * @see https://developer.chrome.com/extensions/input.ime.html#type-InputContext |
5284 * @constructor | 5317 * @constructor |
5285 */ | 5318 */ |
5286 function InputContext() {} | 5319 function InputContext() {} |
5287 | 5320 |
5288 | 5321 |
5289 /** @type {number} */ | 5322 /** @type {number} */ |
5290 InputContext.prototype.contextID; | 5323 InputContext.prototype.contextID; |
(...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6040 * items: (!Array.<!chrome.notifications.NotificationItem>|undefined), | 6073 * items: (!Array.<!chrome.notifications.NotificationItem>|undefined), |
6041 * progress: (number|undefined), | 6074 * progress: (number|undefined), |
6042 * isClickable: (boolean|undefined) | 6075 * isClickable: (boolean|undefined) |
6043 * }} | 6076 * }} |
6044 * @see http://developer.chrome.com/extensions/notifications.html#type-Notificat
ionOptions | 6077 * @see http://developer.chrome.com/extensions/notifications.html#type-Notificat
ionOptions |
6045 */ | 6078 */ |
6046 chrome.notifications.NotificationOptions; | 6079 chrome.notifications.NotificationOptions; |
6047 | 6080 |
6048 | 6081 |
6049 /** | 6082 /** |
6050 * @typedef {function(string): void} | |
6051 * @see http://developer.chrome.com/extensions/notifications.html#method-create | |
6052 * @see http://developer.chrome.com/extensions/notifications.html#event-onClicke
d | |
6053 */ | |
6054 chrome.notifications.StringCallback; | |
6055 | |
6056 | |
6057 /** | |
6058 * @typedef {function(boolean): void} | 6083 * @typedef {function(boolean): void} |
6059 * @see http://developer.chrome.com/extensions/notifications.html#method-update | 6084 * @see http://developer.chrome.com/extensions/notifications.html#method-update |
6060 * @see http://developer.chrome.com/extensions/notifications.html#method-clear | 6085 * @see http://developer.chrome.com/extensions/notifications.html#method-clear |
6061 */ | 6086 */ |
6062 chrome.notifications.BooleanCallback; | 6087 chrome.notifications.BooleanCallback; |
6063 | 6088 |
6064 | 6089 |
6065 /** | 6090 /** |
6066 * @typedef {function(!Object): void} | 6091 * @typedef {function(!Object): void} |
6067 * @see http://developer.chrome.com/extensions/notifications.html#method-getAll | 6092 * @see http://developer.chrome.com/extensions/notifications.html#method-getAll |
(...skipping 11 matching lines...) Expand all Loading... |
6079 /** | 6104 /** |
6080 * @typedef {function(string, number): void} | 6105 * @typedef {function(string, number): void} |
6081 * @see http://developer.chrome.com/extensions/notifications.html#event-onButton
Clicked | 6106 * @see http://developer.chrome.com/extensions/notifications.html#event-onButton
Clicked |
6082 */ | 6107 */ |
6083 chrome.notifications.ButtonCallback; | 6108 chrome.notifications.ButtonCallback; |
6084 | 6109 |
6085 | 6110 |
6086 /** | 6111 /** |
6087 * @param {string} notificationId | 6112 * @param {string} notificationId |
6088 * @param {!chrome.notifications.NotificationOptions} options | 6113 * @param {!chrome.notifications.NotificationOptions} options |
6089 * @param {!chrome.notifications.StringCallback} callback | 6114 * @param {function(string): void} callback |
6090 * @see http://developer.chrome.com/extensions/notifications.html#method-create | 6115 * @see http://developer.chrome.com/extensions/notifications.html#method-create |
6091 */ | 6116 */ |
6092 chrome.notifications.create = function(notificationId, options, callback) {}; | 6117 chrome.notifications.create = function(notificationId, options, callback) {}; |
6093 | 6118 |
6094 | 6119 |
6095 /** | 6120 /** |
6096 * @param {string} notificationId | 6121 * @param {string} notificationId |
6097 * @param {!chrome.notifications.NotificationOptions} options | 6122 * @param {!chrome.notifications.NotificationOptions} options |
6098 * @param {!chrome.notifications.BooleanCallback} callback | 6123 * @param {!chrome.notifications.BooleanCallback} callback |
6099 * @see http://developer.chrome.com/extensions/notifications.html#method-update | 6124 * @see http://developer.chrome.com/extensions/notifications.html#method-update |
(...skipping 11 matching lines...) Expand all Loading... |
6111 | 6136 |
6112 /** | 6137 /** |
6113 * @see http://developer.chrome.com/extensions/notifications.html#method-getAll | 6138 * @see http://developer.chrome.com/extensions/notifications.html#method-getAll |
6114 * @param {!chrome.notifications.ObjectCallback} callback | 6139 * @param {!chrome.notifications.ObjectCallback} callback |
6115 */ | 6140 */ |
6116 chrome.notifications.getAll = function(callback) {}; | 6141 chrome.notifications.getAll = function(callback) {}; |
6117 | 6142 |
6118 | 6143 |
6119 /** | 6144 /** |
6120 * @see http://developer.chrome.com/extensions/notifications.html#method-getPerm
issionLevel | 6145 * @see http://developer.chrome.com/extensions/notifications.html#method-getPerm
issionLevel |
6121 * @param {function(string)} callback takes 'granted' or 'denied' | 6146 * @param {function(string): void} callback takes 'granted' or 'denied' |
6122 */ | 6147 */ |
6123 chrome.notifications.getPermissionLevel = function(callback) {}; | 6148 chrome.notifications.getPermissionLevel = function(callback) {}; |
6124 | 6149 |
6125 | 6150 |
6126 /** | 6151 /** |
6127 * @type {!chrome.notifications.ClosedEvent} | 6152 * @type {!chrome.notifications.ClosedEvent} |
6128 * @see http://developer.chrome.com/extensions/notifications.html#event-onClosed | 6153 * @see http://developer.chrome.com/extensions/notifications.html#event-onClosed |
6129 */ | 6154 */ |
6130 chrome.notifications.onClosed; | 6155 chrome.notifications.onClosed; |
6131 | 6156 |
6132 | 6157 |
6133 /** | 6158 /** |
6134 * @type {!chrome.notifications.ClickedEvent} | 6159 * The user clicked a non-button area of the notification. Callback receives a |
| 6160 * notificationId. |
| 6161 * @type {!ChromeStringEvent} |
6135 * @see http://developer.chrome.com/extensions/notifications.html#event-onClicke
d | 6162 * @see http://developer.chrome.com/extensions/notifications.html#event-onClicke
d |
6136 */ | 6163 */ |
6137 chrome.notifications.onClicked; | 6164 chrome.notifications.onClicked; |
6138 | 6165 |
6139 | 6166 |
6140 /** | 6167 /** |
6141 * @type {!chrome.notifications.ButtonClickedEvent} | 6168 * @type {!chrome.notifications.ButtonClickedEvent} |
6142 * @see http://developer.chrome.com/extensions/notifications.html#event-onButton
Clicked | 6169 * @see http://developer.chrome.com/extensions/notifications.html#event-onButton
Clicked |
6143 */ | 6170 */ |
6144 chrome.notifications.onButtonClicked; | 6171 chrome.notifications.onButtonClicked; |
6145 | 6172 |
6146 | 6173 |
| 6174 /** |
| 6175 * Indicates permission level change. Callback should expect 'granted' or |
| 6176 * 'denied'. |
| 6177 * @type {!ChromeStringEvent} |
| 6178 * @see http://developer.chrome.com/extensions/notifications.html#event-onPermis
sionLevelChanged |
| 6179 */ |
| 6180 chrome.notifications.onPermissionLevelChanged; |
| 6181 |
| 6182 |
| 6183 /** |
| 6184 * @type {!ChromeEvent} |
| 6185 * @see http://developer.chrome.com/extensions/notifications.html#event-onShowSe
ttings |
| 6186 */ |
| 6187 chrome.notifications.onShowSettings; |
| 6188 |
| 6189 |
6147 | 6190 |
6148 /** | 6191 /** |
6149 * @interface | 6192 * @interface |
6150 * @see http://developer.chrome.com/extensions/notifications.html#event-onClosed | 6193 * @see http://developer.chrome.com/extensions/notifications.html#event-onClosed |
6151 */ | 6194 */ |
6152 chrome.notifications.ClosedEvent = function() {}; | 6195 chrome.notifications.ClosedEvent = function() {}; |
6153 | 6196 |
6154 | 6197 |
6155 /** | 6198 /** |
6156 * @param {!chrome.notifications.ClosedCallback} callback | 6199 * @param {!chrome.notifications.ClosedCallback} callback |
(...skipping 17 matching lines...) Expand all Loading... |
6174 | 6217 |
6175 /** | 6218 /** |
6176 * @return {boolean} | 6219 * @return {boolean} |
6177 */ | 6220 */ |
6178 chrome.notifications.ClosedEvent.prototype.hasListeners = function() {}; | 6221 chrome.notifications.ClosedEvent.prototype.hasListeners = function() {}; |
6179 | 6222 |
6180 | 6223 |
6181 | 6224 |
6182 /** | 6225 /** |
6183 * @interface | 6226 * @interface |
6184 * @see http://developer.chrome.com/extensions/notifications.html#event-onClicke
d | |
6185 */ | |
6186 chrome.notifications.ClickedEvent = function() {}; | |
6187 | |
6188 | |
6189 /** | |
6190 * @param {!chrome.notifications.StringCallback} callback | |
6191 */ | |
6192 chrome.notifications.ClickedEvent.prototype.addListener = function(callback) {}; | |
6193 | |
6194 | |
6195 /** | |
6196 * @param {!chrome.notifications.StringCallback} callback | |
6197 */ | |
6198 chrome.notifications.ClickedEvent.prototype.removeListener = | |
6199 function(callback) {}; | |
6200 | |
6201 | |
6202 /** | |
6203 * @param {!chrome.notifications.StringCallback} callback | |
6204 * @return {boolean} | |
6205 */ | |
6206 chrome.notifications.ClickedEvent.prototype.hasListener = function(callback) {}; | |
6207 | |
6208 | |
6209 /** | |
6210 * @return {boolean} | |
6211 */ | |
6212 chrome.notifications.ClickedEvent.prototype.hasListeners = function() {}; | |
6213 | |
6214 | |
6215 | |
6216 /** | |
6217 * @interface | |
6218 * @see http://developer.chrome.com/extensions/notifications.html#event-onButton
Clicked | 6227 * @see http://developer.chrome.com/extensions/notifications.html#event-onButton
Clicked |
6219 */ | 6228 */ |
6220 chrome.notifications.ButtonClickedEvent = function() {}; | 6229 chrome.notifications.ButtonClickedEvent = function() {}; |
6221 | 6230 |
6222 | 6231 |
6223 /** | 6232 /** |
6224 * @param {!chrome.notifications.ButtonCallback} callback | 6233 * @param {!chrome.notifications.ButtonCallback} callback |
6225 */ | 6234 */ |
6226 chrome.notifications.ButtonClickedEvent.prototype.addListener = | 6235 chrome.notifications.ButtonClickedEvent.prototype.addListener = |
6227 function(callback) {}; | 6236 function(callback) {}; |
(...skipping 1112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7340 function(callback) {}; | 7349 function(callback) {}; |
7341 | 7350 |
7342 | 7351 |
7343 /** @return {boolean} */ | 7352 /** @return {boolean} */ |
7344 chrome.bluetoothPrivate.PairingEventEvent.prototype.hasListeners = | 7353 chrome.bluetoothPrivate.PairingEventEvent.prototype.hasListeners = |
7345 function() {}; | 7354 function() {}; |
7346 | 7355 |
7347 | 7356 |
7348 /** @type {!chrome.bluetoothPrivate.PairingEventEvent} */ | 7357 /** @type {!chrome.bluetoothPrivate.PairingEventEvent} */ |
7349 chrome.bluetoothPrivate.onPairing; | 7358 chrome.bluetoothPrivate.onPairing; |
OLD | NEW |