OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 [ | 5 [ |
6 { | 6 { |
7 "namespace": "webstore", | 7 "namespace": "webstore", |
8 "description": "Use the <code>chrome.webstore</code> API to initiate app and extension installations \"inline\" from your site.", | 8 "description": "Use the <code>chrome.webstore</code> API to initiate app and extension installations \"inline\" from your site.", |
9 "types": [ | |
10 { | |
11 "id": "InstallStage", | |
12 "type": "string", | |
13 "enum": ["installing", "downloading"], | |
14 "description": "Enum used to indicate the stage of the installation proc ess. 'downloading' indicates that the necessary files are being downloaded, and 'installing' indicates that the files are downloaded and are being actively inst alled." | |
15 } | |
16 ], // types | |
17 "events": [ | |
18 { | |
19 "name": "onInstallStageChanged", | |
20 "description": "Fired when an inline installation enters a new InstallSt age.", | |
21 "type": "function", | |
22 "parameters": [ | |
23 { | |
24 "name": "stage", | |
25 "$ref": "InstallStage", | |
26 "description": "The InstallStage that just began." | |
27 } | |
28 ] | |
asargent_no_longer_on_chrome
2014/03/03 18:49:08
For future proofing if we ever decided to allow mu
Devlin
2014/03/03 21:15:13
I was wondering about that as well. If we ever do
asargent_no_longer_on_chrome
2014/03/03 22:25:33
Yeah, it would probably be ok to leave this for a
| |
29 }, // onInstallStageChanged | |
30 { | |
31 "name": "onDownloadProgress", | |
32 "description": "Fired periodically with the download progress of an inli ne install.", | |
33 "type": "function", | |
34 "parameters": [ | |
35 { | |
36 "name": "percentDownloaded", | |
37 "type": "number", | |
38 "description": "The progress of the download, between 0 and 1. 0 ind icates no progress; 1.0 indicates complete." | |
39 } | |
40 ] | |
41 } // onDownloadProgress | |
42 ], // events | |
9 "functions": [ | 43 "functions": [ |
10 { | 44 { |
11 "name": "install", | 45 "name": "install", |
12 "allowAmbiguousOptionalArguments": true, | 46 "allowAmbiguousOptionalArguments": true, |
13 "parameters": [ | 47 "parameters": [ |
14 { | 48 { |
15 "name": "url", | 49 "name": "url", |
16 "type": "string", | 50 "type": "string", |
17 "optional": true, | 51 "optional": true, |
18 "description": "If you have more than one <code><link></code> tag on your page with the <code>chrome-webstore-item</code> relation, you can ch oose which item you'd like to install by passing in its URL here. If it is omitt ed, then the first (or only) link will be used. An exception will be thrown if t he passed in URL does not exist on the page." | 52 "description": "If you have more than one <code><link></code> tag on your page with the <code>chrome-webstore-item</code> relation, you can ch oose which item you'd like to install by passing in its URL here. If it is omitt ed, then the first (or only) link will be used. An exception will be thrown if t he passed in URL does not exist on the page." |
(...skipping 13 matching lines...) Expand all Loading... | |
32 { | 66 { |
33 "name": "error", | 67 "name": "error", |
34 "type": "string", | 68 "type": "string", |
35 "description": "The failure detail. You may wish to inspect or l og this for debugging purposes, but you should not rely on specific strings bein g passed back." | 69 "description": "The failure detail. You may wish to inspect or l og this for debugging purposes, but you should not rely on specific strings bein g passed back." |
36 } | 70 } |
37 ], | 71 ], |
38 "description": "This function is invoked when inline installation do es not successfully complete. Possible reasons for this include the user canceli ng the dialog, the linked item not being found in the store, or the install bein g initiated from a non-verified site." | 72 "description": "This function is invoked when inline installation do es not successfully complete. Possible reasons for this include the user canceli ng the dialog, the linked item not being found in the store, or the install bein g initiated from a non-verified site." |
39 } | 73 } |
40 ] | 74 ] |
41 } // install | 75 } // install |
42 ] | 76 ] // functions |
43 } // webstore | 77 } // webstore |
44 ] | 78 ] |
OLD | NEW |