| 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 * @fileoverview This file is the controller for generating extension | 6 * @fileoverview This file is the controller for generating extension |
| 7 * doc pages. | 7 * doc pages. |
| 8 * | 8 * |
| 9 * It expects to have available via XHR (relative path): | 9 * It expects to have available via XHR (relative path): |
| 10 * 1) API_TEMPLATE which is the main template for the api pages. | 10 * 1) API_TEMPLATE which is the main template for the api pages. |
| 11 * 2) The files located at MODULE_SCHEMAS which are shared with the extension | 11 * 2) The files located at MODULE_SCHEMAS which are shared with the extension |
| 12 * system and defines the methods and events contained in one api. | 12 * system and defines the methods and events contained in one api. |
| 13 * 3) (Possibly) A static version of the current page url in /static/. I.e. | 13 * 3) (Possibly) A static version of the current page url in /static/. I.e. |
| 14 * if called as ../foo.html, it will look for ../static/foo.html. | 14 * if called as ../foo.html, it will look for ../static/foo.html. |
| 15 * | 15 * |
| 16 * The "shell" page may have a renderering already contained within it so that | 16 * The "shell" page may have a renderering already contained within it so that |
| 17 * the docs can be indexed. | 17 * the docs can be indexed. |
| 18 * | 18 * |
| 19 */ | 19 */ |
| 20 | 20 |
| 21 var API_TEMPLATE = 'template/api_template.html'; | 21 var API_TEMPLATE = 'template/api_template.html'; |
| 22 var MODULE_SCHEMAS = [ | 22 var MODULE_SCHEMAS = [ |
| 23 '../api/bookmarks.json', | 23 '../api/bookmarks.json', |
| 24 '../api/browserAction.json', | 24 '../api/browserAction.json', |
| 25 '../api/browsingData.json', |
| 25 '../api/chromeAuthPrivate.json', | 26 '../api/chromeAuthPrivate.json', |
| 26 '../api/chromePrivate.json', | 27 '../api/chromePrivate.json', |
| 27 '../api/chromeosInfoPrivate.json', | 28 '../api/chromeosInfoPrivate.json', |
| 28 '../api/contentSettings.json', | 29 '../api/contentSettings.json', |
| 29 '../api/contextMenus.json', | 30 '../api/contextMenus.json', |
| 30 '../api/cookies.json', | 31 '../api/cookies.json', |
| 31 '../api/debugger.json', | 32 '../api/debugger.json', |
| 32 '../api/devtools.json', | 33 '../api/devtools.json', |
| 33 '../api/experimental.accessibility.json', | 34 '../api/experimental.accessibility.json', |
| 34 '../api/experimental.app.json', | 35 '../api/experimental.app.json', |
| 35 '../api/experimental.bookmarkManager.json', | 36 '../api/experimental.bookmarkManager.json', |
| 36 '../api/experimental.browsingData.json', | |
| 37 '../api/experimental.dns.json', | 37 '../api/experimental.dns.json', |
| 38 '../api/experimental.downloads.json', | 38 '../api/experimental.downloads.json', |
| 39 '../api/experimental.extension.json', | 39 '../api/experimental.extension.json', |
| 40 '../api/experimental.infobars.json', | 40 '../api/experimental.infobars.json', |
| 41 '../api/experimental.input.ui.json', | 41 '../api/experimental.input.ui.json', |
| 42 '../api/experimental.input.virtualKeyboard.json', | 42 '../api/experimental.input.virtualKeyboard.json', |
| 43 '../api/experimental.processes.json', | 43 '../api/experimental.processes.json', |
| 44 '../api/experimental.rlz.json', | 44 '../api/experimental.rlz.json', |
| 45 '../api/experimental.serial.json', | 45 '../api/experimental.serial.json', |
| 46 '../api/experimental.socket.json', | 46 '../api/experimental.socket.json', |
| (...skipping 622 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 669 } | 669 } |
| 670 if (a.name > b.name) { | 670 if (a.name > b.name) { |
| 671 return 1; | 671 return 1; |
| 672 } | 672 } |
| 673 return 0; | 673 return 0; |
| 674 } | 674 } |
| 675 | 675 |
| 676 function disableDocs(obj) { | 676 function disableDocs(obj) { |
| 677 return !!obj.nodoc || !!obj.internal; | 677 return !!obj.nodoc || !!obj.internal; |
| 678 } | 678 } |
| OLD | NEW |