Chromium Code Reviews| Index: chrome/common/extensions/api/system_storage.idl |
| diff --git a/chrome/common/extensions/api/system_storage.idl b/chrome/common/extensions/api/system_storage.idl |
| index 33338d4a1ed40c70fccbe0a154fa54b671974b14..fc64ef08e04cac55616d56be4dcfa1093d4a3cc0 100644 |
| --- a/chrome/common/extensions/api/system_storage.idl |
| +++ b/chrome/common/extensions/api/system_storage.idl |
| @@ -30,6 +30,13 @@ namespace system.storage { |
| double capacity; |
| }; |
| + dictionary StorageAvailableCapacityInfo { |
| + // The same |id| from the getAvailableCapacity function parameter |id|. |
|
not at google - send to devlin
2013/10/18 00:33:11
I can't parse this sentence
Haojian Wu
2013/10/18 00:47:38
Done.
|
| + DOMString id; |
| + // The available capacity of the storage device, in bytes. |
| + double availableCapacity; |
| + }; |
| + |
| [inline_doc] enum EjectDeviceResultCode { |
| // The ejection command is successful -- the application can prompt the user |
| // to remove the device. |
| @@ -48,6 +55,9 @@ namespace system.storage { |
| callback StorageInfoCallback = void (StorageUnitInfo[] info); |
| + callback getAvailableCapacityCallback = void ( |
|
not at google - send to devlin
2013/10/18 00:33:11
get -> Get
Haojian Wu
2013/10/18 00:47:38
The extension api name should follow this way(the
|
| + StorageAvailableCapacityInfo info); |
| + |
| interface Functions { |
| // Get the storage information from the system. The argument passed to the |
| // callback is an array of StorageUnitInfo objects. |
| @@ -55,6 +65,11 @@ namespace system.storage { |
| // Ejects a removable storage device. |
| static void ejectDevice(DOMString id, EjectDeviceCallback callback); |
| + |
| + // Get the available capacity of a specified |id| storage device. |
| + // The |id| is the transient device ID from StorageUnitInfo. |
| + static void getAvailableCapacity(DOMString id, |
| + getAvailableCapacityCallback callback); |
| }; |
| interface Events { |
| @@ -66,4 +81,3 @@ namespace system.storage { |
| }; |
| }; |
| - |