| 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 // developerPrivate API. | 5 // developerPrivate API. |
| 6 // This is a private API exposing developing and debugging functionalities for | 6 // This is a private API exposing developing and debugging functionalities for |
| 7 // apps and extensions. | 7 // apps and extensions. |
| 8 namespace developerPrivate { | 8 namespace developerPrivate { |
| 9 | 9 |
| 10 // DEPRECATED: Prefer ExtensionType. | 10 // DEPRECATED: Prefer ExtensionType. |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 | 142 |
| 143 dictionary ExtensionView { | 143 dictionary ExtensionView { |
| 144 DOMString url; | 144 DOMString url; |
| 145 long renderProcessId; | 145 long renderProcessId; |
| 146 long renderViewId; | 146 long renderViewId; |
| 147 boolean incognito; | 147 boolean incognito; |
| 148 ViewType type; | 148 ViewType type; |
| 149 }; | 149 }; |
| 150 | 150 |
| 151 dictionary ExtensionInfo { | 151 dictionary ExtensionInfo { |
| 152 boolean actionButtonHidden; | 152 boolean actionButtonHidden; // enable_show_button |
| 153 DOMString? blacklistText; | 153 DOMString? blacklistText; |
| 154 DOMString[] dependentExtensions; | 154 DOMString[] dependentExtensions; |
| 155 DOMString description; | 155 DOMString description; |
| 156 DisableReasons disableReasons; | 156 DisableReasons disableReasons; //suspicious, corrupt, updaterequired |
| 157 AccessModifier errorCollection; | 157 AccessModifier errorCollection; // errorCollectionEd, wantsErrorCollection; |
| 158 AccessModifier fileAccess; | 158 AccessModifier fileAccess; // allowFileAccess, wantsFileAccess |
| 159 HomePage homePage; | 159 HomePage homePage; // homepageProvided && homepageUrl |
| 160 DOMString iconUrl; | 160 DOMString iconUrl; // icon |
| 161 DOMString id; | 161 DOMString id; |
| 162 AccessModifier incognitoAccess; | 162 AccessModifier incognitoAccess; // enabled/can be enabled incognito |
| 163 boolean installedByCustodian; | 163 boolean installedByCustodian; |
| 164 DOMString[] installWarnings; | 164 DOMString[] installWarnings; |
| 165 DOMString? launchUrl; | 165 DOMString? launchUrl; |
| 166 Location location; | 166 Location location; // is_unpacked, is from store, allow reload |
| 167 DOMString? locationText; | 167 DOMString? locationText; |
| 168 ManifestError[] manifestErrors; | 168 ManifestError[] manifestErrors; |
| 169 boolean mustRemainInstalled; | 169 boolean mustRemainInstalled; // recommendedInstall |
| 170 DOMString name; | 170 DOMString name; |
| 171 boolean offlineEnabled; | 171 boolean offlineEnabled; |
| 172 OptionsPage? optionsPage; | 172 OptionsPage? optionsPage; |
| 173 DOMString? path; | 173 DOMString? path; |
| 174 DOMString? policyText; | 174 DOMString? policyText; |
| 175 DOMString? prettifiedPath; | 175 DOMString? prettifiedPath; |
| 176 AccessModifier runOnAllUrls; | 176 AccessModifier runOnAllUrls; // allowAllUrls, showAllUrls |
| 177 RuntimeError[] runtimeErrors; | 177 RuntimeError[] runtimeErrors; |
| 178 DOMString[] runtimeWarnings; | 178 DOMString[] runtimeWarnings; // warnings |
| 179 ExtensionState state; | 179 ExtensionState state; |
| 180 ExtensionType type; | 180 ExtensionType type; // is_hosted_app, is_platform_app, etc |
| 181 DOMString updateUrl; | 181 DOMString updateUrl; |
| 182 boolean userMayModify; | 182 boolean userMayModify; // managed install |
| 183 DOMString version; | 183 DOMString version; |
| 184 ExtensionView[] views; | 184 ExtensionView[] views; |
| 185 }; | 185 }; |
| 186 | 186 |
| 187 dictionary ProfileInfo { | |
| 188 boolean appInfoDialogEnabled; | |
| 189 boolean canLoadUnpacked; | |
| 190 boolean inDeveloperMode; | |
| 191 boolean isIncognitoAvailable; | |
| 192 boolean isSupervised; | |
| 193 }; | |
| 194 | |
| 195 // DEPRECATED: Prefer ExtensionInfo. | 187 // DEPRECATED: Prefer ExtensionInfo. |
| 196 dictionary ItemInfo { | 188 dictionary ItemInfo { |
| 197 DOMString id; | 189 DOMString id; |
| 198 DOMString name; | 190 DOMString name; |
| 199 DOMString version; | 191 DOMString version; |
| 200 DOMString description; | 192 DOMString description; |
| 201 boolean may_disable; | 193 boolean may_disable; |
| 202 boolean enabled; | 194 boolean enabled; |
| 203 boolean isApp; | 195 boolean isApp; |
| 204 ItemType type; | 196 ItemType type; |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 236 | 228 |
| 237 dictionary ExtensionConfigurationUpdate { | 229 dictionary ExtensionConfigurationUpdate { |
| 238 DOMString extensionId; | 230 DOMString extensionId; |
| 239 boolean? fileAccess; | 231 boolean? fileAccess; |
| 240 boolean? incognitoAccess; | 232 boolean? incognitoAccess; |
| 241 boolean? errorCollection; | 233 boolean? errorCollection; |
| 242 boolean? runOnAllUrls; | 234 boolean? runOnAllUrls; |
| 243 boolean? showActionButton; | 235 boolean? showActionButton; |
| 244 }; | 236 }; |
| 245 | 237 |
| 246 dictionary ProfileConfigurationUpdate { | |
| 247 boolean? inDeveloperMode; | |
| 248 }; | |
| 249 | |
| 250 dictionary ReloadOptions { | 238 dictionary ReloadOptions { |
| 251 // If false, an alert dialog will show in the event of a reload error. | 239 // If false, an alert dialog will show in the event of a reload error. |
| 252 // Defaults to false. | 240 // Defaults to false. |
| 253 boolean? failQuietly; | 241 boolean? failQuietly; |
| 254 }; | 242 }; |
| 255 | 243 |
| 256 dictionary LoadUnpackedOptions { | 244 dictionary LoadUnpackedOptions { |
| 257 // If false, an alert dialog will show in the event of a reload error. | 245 // If false, an alert dialog will show in the event of a reload error. |
| 258 // Defaults to false. | 246 // Defaults to false. |
| 259 boolean? failQuietly; | 247 boolean? failQuietly; |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 380 DOMString extensionId; | 368 DOMString extensionId; |
| 381 long[]? errorIds; | 369 long[]? errorIds; |
| 382 ErrorType? type; | 370 ErrorType? type; |
| 383 }; | 371 }; |
| 384 | 372 |
| 385 callback VoidCallback = void (); | 373 callback VoidCallback = void (); |
| 386 callback BooleanCallback = void (boolean result); | 374 callback BooleanCallback = void (boolean result); |
| 387 callback ExtensionInfosCallback = void (ExtensionInfo[] result); | 375 callback ExtensionInfosCallback = void (ExtensionInfo[] result); |
| 388 callback ExtensionInfoCallback = void (ExtensionInfo result); | 376 callback ExtensionInfoCallback = void (ExtensionInfo result); |
| 389 callback ItemsInfoCallback = void (ItemInfo[] result); | 377 callback ItemsInfoCallback = void (ItemInfo[] result); |
| 390 callback ProfileInfoCallback = void (ProfileInfo info); | |
| 391 callback GetProjectsInfoCallback = void (ProjectInfo[] result); | 378 callback GetProjectsInfoCallback = void (ProjectInfo[] result); |
| 392 callback PathCallback = void (DOMString path); | 379 callback PathCallback = void (DOMString path); |
| 393 callback PackCallback = void (PackDirectoryResponse response); | 380 callback PackCallback = void (PackDirectoryResponse response); |
| 394 callback VoidCallback = void(); | 381 callback VoidCallback = void(); |
| 395 callback RequestFileSourceCallback = | 382 callback RequestFileSourceCallback = |
| 396 void (RequestFileSourceResponse response); | 383 void (RequestFileSourceResponse response); |
| 397 | 384 |
| 398 interface Functions { | 385 interface Functions { |
| 399 // Runs auto update for extensions and apps immediately. | 386 // Runs auto update for extensions and apps immediately. |
| 400 // |callback| : Called with the boolean result, true if autoUpdate is | 387 // |callback| : Called with the boolean result, true if autoUpdate is |
| (...skipping 14 matching lines...) Expand all Loading... |
| 415 | 402 |
| 416 // Returns information of all the extensions and apps installed. | 403 // Returns information of all the extensions and apps installed. |
| 417 // |includeDisabled| : include disabled items. | 404 // |includeDisabled| : include disabled items. |
| 418 // |includeTerminated| : include terminated items. | 405 // |includeTerminated| : include terminated items. |
| 419 // |callback| : Called with items info. | 406 // |callback| : Called with items info. |
| 420 [deprecated="Use getExtensionsInfo"] static void getItemsInfo( | 407 [deprecated="Use getExtensionsInfo"] static void getItemsInfo( |
| 421 boolean includeDisabled, | 408 boolean includeDisabled, |
| 422 boolean includeTerminated, | 409 boolean includeTerminated, |
| 423 ItemsInfoCallback callback); | 410 ItemsInfoCallback callback); |
| 424 | 411 |
| 425 // Returns the current profile's configuration. | |
| 426 static void getProfileConfiguration(ProfileInfoCallback callback); | |
| 427 | |
| 428 // Updates the active profile. | |
| 429 // |update| : The parameters for updating the profile's configuration. Any | |
| 430 // properties omitted from |update| will not be changed. | |
| 431 static void updateProfileConfiguration(ProfileConfigurationUpdate update, | |
| 432 optional VoidCallback callback); | |
| 433 | |
| 434 // Opens a permissions dialog. | 412 // Opens a permissions dialog. |
| 435 // |extensionId| : The id of the extension to show permissions for. | 413 // |extensionId| : The id of the extension to show permissions for. |
| 436 static void showPermissionsDialog(DOMString extensionId, | 414 static void showPermissionsDialog(DOMString extensionId, |
| 437 optional VoidCallback callback); | 415 optional VoidCallback callback); |
| 438 | 416 |
| 439 // Reloads a given extension. | 417 // Reloads a given extension. |
| 440 // |extensionId| : The id of the extension to reload. | 418 // |extensionId| : The id of the extension to reload. |
| 441 // |options| : Additional configuration parameters. | 419 // |options| : Additional configuration parameters. |
| 442 static void reload(DOMString extensionId, | 420 static void reload(DOMString extensionId, |
| 443 optional ReloadOptions options, | 421 optional ReloadOptions options, |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 514 static void inspect(InspectOptions options, | 492 static void inspect(InspectOptions options, |
| 515 optional VoidCallback callback); | 493 optional VoidCallback callback); |
| 516 }; | 494 }; |
| 517 | 495 |
| 518 interface Events { | 496 interface Events { |
| 519 // Fired when a item state is changed. | 497 // Fired when a item state is changed. |
| 520 static void onItemStateChanged(EventData response); | 498 static void onItemStateChanged(EventData response); |
| 521 }; | 499 }; |
| 522 | 500 |
| 523 }; | 501 }; |
| OLD | NEW |