| OLD | NEW | 
|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 /** @fileoverview Externs generated from namespace: developerPrivate */ | 5 /** @fileoverview Externs generated from namespace: developerPrivate */ | 
| 6 | 6 | 
| 7 // Note: hand-modified to change Array to !Array in ItemInfo typedef, and add | 7 // Note: hand-modified to change Array to !Array in ItemInfo typedef, and add | 
| 8 // enum definitions. | 8 // enum definitions. | 
| 9 | 9 | 
| 10 /** | 10 /** | 
| 11  * @typedef {string} | 11  * @typedef {string} | 
| 12  */ | 12  */ | 
| 13 var ItemType; | 13 var ItemType; | 
| 14 | 14 | 
| 15 /** | 15 /** | 
| 16  * @typedef {{ | 16  * @typedef {{ | 
| 17  *   path: string, | 17  *   path: string, | 
| 18  *   render_process_id: number, | 18  *   render_process_id: number, | 
| 19  *   render_view_id: number, | 19  *   render_view_id: number, | 
| 20  *   incognito: boolean, | 20  *   incognito: boolean, | 
| 21  *   generatedBackgroundPage: boolean | 21  *   generatedBackgroundPage: boolean | 
| 22  * }} | 22  * }} | 
| 23  */ | 23  */ | 
| 24 var ItemInspectView; | 24 var ItemInspectView; | 
| 25 | 25 | 
| 26 /** | 26 /** | 
|  | 27  * @enum {string} | 
|  | 28  */ | 
|  | 29 chrome.developerPrivate.ExtensionType = { | 
|  | 30   HOSTED_APP: 'HOSTED_APP', | 
|  | 31   PLATFORM_APP: 'PLATFORM_APP', | 
|  | 32   LEGACY_PACKAGED_APP: 'LEGACY_PACKAGED_APP', | 
|  | 33   EXTENSION: 'EXTENSION', | 
|  | 34   THEME: 'THEME', | 
|  | 35   SHARED_MODULE: 'SHARED_MODULE' | 
|  | 36 }; | 
|  | 37 | 
|  | 38 /** | 
|  | 39  * @enum {string} | 
|  | 40  */ | 
|  | 41 chrome.developerPrivate.Location = { | 
|  | 42   FROM_STORE: 'FROM_STORE', | 
|  | 43   UNPACKED: 'UNPACKED', | 
|  | 44   THIRD_PARTY: 'THIRD_PARTY', | 
|  | 45   UNKNOWN: 'UNKNOWN' | 
|  | 46 }; | 
|  | 47 | 
|  | 48 /** | 
|  | 49  * @enum {string} | 
|  | 50  */ | 
|  | 51 chrome.developerPrivate.ViewType = { | 
|  | 52   APP_WINDOW: 'APP_WINDOW', | 
|  | 53   BACKGROUND_CONTENTS: 'BACKGROUND_CONTENTS', | 
|  | 54   EXTENSION_BACKGROUND_PAGE: 'EXTENSION_BACKGROUND_PAGE', | 
|  | 55   EXTENSION_DIALOG: 'EXTENSION_DIALOG', | 
|  | 56   EXTENSION_POPUP: 'EXTENSION_POPUP', | 
|  | 57   LAUNCHER_PAGE: 'LAUNCHER_PAGE', | 
|  | 58   PANEL: 'PANEL', | 
|  | 59   TAB_CONTENTS: 'TAB_CONTENTS', | 
|  | 60   VIRTUAL_KEYBOARD: 'VIRTUAL_KEYBOARD' | 
|  | 61 }; | 
|  | 62 | 
|  | 63 /** | 
|  | 64  * @enum {string} | 
|  | 65  */ | 
|  | 66 chrome.developerPrivate.ErrorType = { | 
|  | 67   MANIFEST: 'MANIFEST', | 
|  | 68   RUNTIME: 'RUNTIME' | 
|  | 69 }; | 
|  | 70 | 
|  | 71 /** | 
|  | 72  * @enum {string} | 
|  | 73  */ | 
|  | 74 chrome.developerPrivate.ErrorLevel = { | 
|  | 75   LOG: 'LOG', | 
|  | 76   WARN: 'WARN', | 
|  | 77   ERROR: 'ERROR' | 
|  | 78 }; | 
|  | 79 | 
|  | 80 /** | 
|  | 81  * @enum {string} | 
|  | 82  */ | 
|  | 83 chrome.developerPrivate.ExtensionState = { | 
|  | 84   ENABLED: 'ENABLED', | 
|  | 85   DISABLED: 'DISABLED', | 
|  | 86   TERMINATED: 'TERMINATED' | 
|  | 87 }; | 
|  | 88 | 
|  | 89 /** | 
| 27  * @typedef {{ | 90  * @typedef {{ | 
| 28  *   message: string | 91  *   message: string | 
| 29  * }} | 92  * }} | 
| 30  */ | 93  */ | 
| 31 var InstallWarning; | 94 var InstallWarning; | 
| 32 | 95 | 
| 33 /** | 96 /** | 
| 34  * @typedef {{ | 97  * @typedef {{ | 
|  | 98  *   isEnabled: boolean, | 
|  | 99  *   isActive: boolean | 
|  | 100  * }} | 
|  | 101  */ | 
|  | 102 var AccessModifier; | 
|  | 103 | 
|  | 104 /** | 
|  | 105  * @typedef {{ | 
|  | 106  *   lineNumber: number, | 
|  | 107  *   columnNumber: number, | 
|  | 108  *   url: string, | 
|  | 109  *   functionName: string | 
|  | 110  * }} | 
|  | 111  */ | 
|  | 112 var StackFrame; | 
|  | 113 | 
|  | 114 /** | 
|  | 115  * @typedef {{ | 
|  | 116  *   type: chrome.developerPrivate.ErrorType, | 
|  | 117  *   extensionId: string, | 
|  | 118  *   fromIncognito: boolean, | 
|  | 119  *   source: string, | 
|  | 120  *   message: string, | 
|  | 121  *   manifestKey: string, | 
|  | 122  *   manifestSpecific: (string|undefined) | 
|  | 123  * }} | 
|  | 124  */ | 
|  | 125 var ManifestError; | 
|  | 126 | 
|  | 127 /** | 
|  | 128  * @typedef {{ | 
|  | 129  *   type: chrome.developerPrivate.ErrorType, | 
|  | 130  *   extensionId: string, | 
|  | 131  *   fromIncognito: boolean, | 
|  | 132  *   source: string, | 
|  | 133  *   message: string, | 
|  | 134  *   severity: chrome.developerPrivate.ErrorLevel, | 
|  | 135  *   contextUrl: string, | 
|  | 136  *   occurrences: number, | 
|  | 137  *   renderViewId: number, | 
|  | 138  *   renderProcessId: number, | 
|  | 139  *   canInspect: boolean, | 
|  | 140  *   stackTrace: Array | 
|  | 141  * }} | 
|  | 142  */ | 
|  | 143 var RuntimeError; | 
|  | 144 | 
|  | 145 /** | 
|  | 146  * @typedef {{ | 
|  | 147  *   suspiciousInstall: boolean, | 
|  | 148  *   corruptInstall: boolean, | 
|  | 149  *   updateRequired: boolean | 
|  | 150  * }} | 
|  | 151  */ | 
|  | 152 var DisableReasons; | 
|  | 153 | 
|  | 154 /** | 
|  | 155  * @typedef {{ | 
|  | 156  *   openInTab: boolean, | 
|  | 157  *   url: string | 
|  | 158  * }} | 
|  | 159  */ | 
|  | 160 var OptionsPage; | 
|  | 161 | 
|  | 162 /** | 
|  | 163  * @typedef {{ | 
|  | 164  *   url: string, | 
|  | 165  *   specified: boolean | 
|  | 166  * }} | 
|  | 167  */ | 
|  | 168 var HomePage; | 
|  | 169 | 
|  | 170 /** | 
|  | 171  * @typedef {{ | 
|  | 172  *   url: string, | 
|  | 173  *   renderProcessId: number, | 
|  | 174  *   renderViewId: number, | 
|  | 175  *   incognito: boolean, | 
|  | 176  *   type: chrome.developerPrivate.ViewType | 
|  | 177  * }} | 
|  | 178  */ | 
|  | 179 var ExtensionView; | 
|  | 180 | 
|  | 181 /** | 
|  | 182  * @typedef {{ | 
|  | 183  *   actionButtonHidden: boolean, | 
|  | 184  *   blacklistText: (string|undefined), | 
|  | 185  *   dependentExtensions: Array, | 
|  | 186  *   description: string, | 
|  | 187  *   disableReasons: DisableReasons, | 
|  | 188  *   errorCollection: AccessModifier, | 
|  | 189  *   fileAccess: AccessModifier, | 
|  | 190  *   homePage: HomePage, | 
|  | 191  *   iconUrl: string, | 
|  | 192  *   id: string, | 
|  | 193  *   incognitoAccess: AccessModifier, | 
|  | 194  *   installedByCustodian: boolean, | 
|  | 195  *   installWarnings: Array, | 
|  | 196  *   launchUrl: (string|undefined), | 
|  | 197  *   location: chrome.developerPrivate.Location, | 
|  | 198  *   locationText: (string|undefined), | 
|  | 199  *   manifestErrors: Array, | 
|  | 200  *   mustRemainInstalled: boolean, | 
|  | 201  *   name: string, | 
|  | 202  *   offlineEnabled: boolean, | 
|  | 203  *   optionsPage: (OptionsPage|undefined), | 
|  | 204  *   path: (string|undefined), | 
|  | 205  *   policyText: (string|undefined), | 
|  | 206  *   prettifiedPath: (string|undefined), | 
|  | 207  *   runOnAllUrls: AccessModifier, | 
|  | 208  *   runtimeErrors: Array, | 
|  | 209  *   runtimeWarnings: Array, | 
|  | 210  *   state: chrome.developerPrivate.ExtensionState, | 
|  | 211  *   type: chrome.developerPrivate.ExtensionType, | 
|  | 212  *   updateUrl: string, | 
|  | 213  *   userMayModify: boolean, | 
|  | 214  *   version: string, | 
|  | 215  *   views: Array | 
|  | 216  * }} | 
|  | 217  */ | 
|  | 218 var ExtensionInfo; | 
|  | 219 | 
|  | 220 /** | 
|  | 221  * @typedef {{ | 
| 35  *   id: string, | 222  *   id: string, | 
| 36  *   name: string, | 223  *   name: string, | 
| 37  *   version: string, | 224  *   version: string, | 
| 38  *   description: string, | 225  *   description: string, | 
| 39  *   may_disable: boolean, | 226  *   may_disable: boolean, | 
| 40  *   enabled: boolean, | 227  *   enabled: boolean, | 
| 41  *   disabled_reason: (string|undefined), |  | 
| 42  *   isApp: boolean, | 228  *   isApp: boolean, | 
| 43  *   type: ItemType, | 229  *   type: ItemType, | 
| 44  *   allow_activity: boolean, | 230  *   allow_activity: boolean, | 
| 45  *   allow_file_access: boolean, | 231  *   allow_file_access: boolean, | 
| 46  *   wants_file_access: boolean, | 232  *   wants_file_access: boolean, | 
| 47  *   incognito_enabled: boolean, | 233  *   incognito_enabled: boolean, | 
| 48  *   is_unpacked: boolean, | 234  *   is_unpacked: boolean, | 
| 49  *   allow_reload: boolean, | 235  *   allow_reload: boolean, | 
| 50  *   terminated: boolean, | 236  *   terminated: boolean, | 
| 51  *   allow_incognito: boolean, | 237  *   allow_incognito: boolean, | 
| 52  *   icon_url: string, | 238  *   icon_url: string, | 
| 53  *   path: (string|undefined), | 239  *   path: (string|undefined), | 
| 54  *   options_url: (string|undefined), | 240  *   options_url: (string|undefined), | 
| 55  *   app_launch_url: (string|undefined), | 241  *   app_launch_url: (string|undefined), | 
| 56  *   homepage_url: (string|undefined), | 242  *   homepage_url: (string|undefined), | 
| 57  *   update_url: (string|undefined), | 243  *   update_url: (string|undefined), | 
| 58  *   install_warnings: !Array, | 244  *   install_warnings: !Array, | 
| 59  *   manifest_errors: !Array, | 245  *   manifest_errors: !Array, | 
| 60  *   runtime_errors: !Array, | 246  *   runtime_errors: !Array, | 
| 61  *   offline_enabled: boolean, | 247  *   offline_enabled: boolean, | 
| 62  *   views: !Array | 248  *   views: !Array | 
| 63  * }} | 249  * }} | 
| 64  */ | 250  */ | 
| 65 var ItemInfo; | 251 var ItemInfo; | 
| 66 | 252 | 
| 67 /** | 253 /** | 
| 68  * @typedef {{ | 254  * @typedef {{ | 
|  | 255  *   includeDisabled: (boolean|undefined), | 
|  | 256  *   includeTerminated: (boolean|undefined) | 
|  | 257  * }} | 
|  | 258  */ | 
|  | 259 var GetExtensionsInfoOptions; | 
|  | 260 | 
|  | 261 /** | 
|  | 262  * @typedef {{ | 
| 69  *   extension_id: string, | 263  *   extension_id: string, | 
| 70  *   render_process_id: (string|number), | 264  *   render_process_id: (string|number), | 
| 71  *   render_view_id: (string|number), | 265  *   render_view_id: (string|number), | 
| 72  *   incognito: boolean | 266  *   incognito: boolean | 
| 73  * }} | 267  * }} | 
| 74  */ | 268  */ | 
| 75 var InspectOptions; | 269 var InspectOptions; | 
| 76 | 270 | 
| 77 /** | 271 /** | 
| 78  * @typedef {{ | 272  * @typedef {{ | 
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 195 | 389 | 
| 196 /** | 390 /** | 
| 197  * Runs auto update for extensions and apps immediately. | 391  * Runs auto update for extensions and apps immediately. | 
| 198  * @param {Function=} callback Called with the boolean result, true if | 392  * @param {Function=} callback Called with the boolean result, true if | 
| 199  * autoUpdate is successful. | 393  * autoUpdate is successful. | 
| 200  */ | 394  */ | 
| 201 chrome.developerPrivate.autoUpdate = function(callback) {}; | 395 chrome.developerPrivate.autoUpdate = function(callback) {}; | 
| 202 | 396 | 
| 203 /** | 397 /** | 
| 204  * Returns information of all the extensions and apps installed. | 398  * Returns information of all the extensions and apps installed. | 
|  | 399  * @param {GetExtensionsInfoOptions=} options Options to restrict the items | 
|  | 400  * returned. | 
|  | 401  * @param {Function=} callback Called with extensions info. | 
|  | 402  */ | 
|  | 403 chrome.developerPrivate.getExtensionsInfo = function(options, callback) {}; | 
|  | 404 | 
|  | 405 /** | 
|  | 406  * Returns information of a particular extension. | 
|  | 407  * @param {string} id The id of the extension. | 
|  | 408  * @param {Function=} callback Called with the result. | 
|  | 409  */ | 
|  | 410 chrome.developerPrivate.getExtensionInfo = function(id, callback) {}; | 
|  | 411 | 
|  | 412 /** | 
|  | 413  * Returns information of all the extensions and apps installed. | 
| 205  * @param {boolean} includeDisabled include disabled items. | 414  * @param {boolean} includeDisabled include disabled items. | 
| 206  * @param {boolean} includeTerminated include terminated items. | 415  * @param {boolean} includeTerminated include terminated items. | 
| 207  * @param {Function} callback Called with items info. | 416  * @param {Function} callback Called with items info. | 
| 208  */ | 417  */ | 
| 209 chrome.developerPrivate.getItemsInfo = function(includeDisabled, includeTerminat
     ed, callback) {}; | 418 chrome.developerPrivate.getItemsInfo = function(includeDisabled, includeTerminat
     ed, callback) {}; | 
| 210 | 419 | 
| 211 /** | 420 /** | 
| 212  * Opens a permissions dialog. | 421  * Opens a permissions dialog. | 
| 213  * @param {string} extensionId The id of the extension to show permissions for. | 422  * @param {string} extensionId The id of the extension to show permissions for. | 
| 214  * @param {Function=} callback | 423  * @param {Function=} callback | 
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 307 chrome.developerPrivate.requestFileSource = function(properties, callback) {}; | 516 chrome.developerPrivate.requestFileSource = function(properties, callback) {}; | 
| 308 | 517 | 
| 309 /** | 518 /** | 
| 310  * Open the developer tools to focus on a particular error. | 519  * Open the developer tools to focus on a particular error. | 
| 311  * @param {OpenDevToolsProperties} properties | 520  * @param {OpenDevToolsProperties} properties | 
| 312  */ | 521  */ | 
| 313 chrome.developerPrivate.openDevTools = function(properties) {}; | 522 chrome.developerPrivate.openDevTools = function(properties) {}; | 
| 314 | 523 | 
| 315 /** @type {!ChromeEvent} */ | 524 /** @type {!ChromeEvent} */ | 
| 316 chrome.developerPrivate.onItemStateChanged; | 525 chrome.developerPrivate.onItemStateChanged; | 
| OLD | NEW | 
|---|