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..04fdd6be51033ecc59a8ea7e5a5795f97230fe6d 100644 |
| --- a/chrome/common/extensions/api/system_storage.idl |
| +++ b/chrome/common/extensions/api/system_storage.idl |
| @@ -30,6 +30,12 @@ namespace system.storage { |
| double capacity; |
| }; |
| + dictionary StorageAvailableCapacityInfo { |
| + DOMString id; |
|
Greg Billock
2013/10/14 20:32:05
Can we arrange to pass this in JS and just return
Haojian Wu
2013/10/15 00:50:26
Yes. We can just return the capacity instead of th
Greg Billock
2013/10/15 15:26:04
Sounds good.
On 2013/10/15 00:50:26, Haojian Wu w
Greg Billock
2013/10/15 15:26:04
Add a comment about this id that it is the same ID
Haojian Wu
2013/10/16 04:04:23
Done.
|
| + // 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 +54,9 @@ namespace system.storage { |
| callback StorageInfoCallback = void (StorageUnitInfo[] info); |
| + callback getAvailableCapacityCallback = void ( |
| + 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 +64,10 @@ 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. |
|
Greg Billock
2013/10/15 15:26:04
Clarify here about id: "... of a specified storage
Haojian Wu
2013/10/16 04:04:23
Done.
|
| + static void getAvailableCapacity(DOMString id, |
| + getAvailableCapacityCallback callback); |
| }; |
| interface Events { |
| @@ -66,4 +79,3 @@ namespace system.storage { |
| }; |
| }; |
| - |