| Index: third_party/chrome/idl/experimental_system_info_storage.idl
|
| diff --git a/third_party/chrome/idl/experimental_system_info_storage.idl b/third_party/chrome/idl/experimental_system_info_storage.idl
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..13ed295ad85680c962d6bbd15ee947ba84792429
|
| --- /dev/null
|
| +++ b/third_party/chrome/idl/experimental_system_info_storage.idl
|
| @@ -0,0 +1,50 @@
|
| +// Copyright (c) 2012 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +namespace experimental.systemInfo.storage {
|
| +
|
| + enum StorageUnitType {
|
| + // Unknow storage type.
|
| + unknown,
|
| + // Hard disk.
|
| + harddisk,
|
| + // Removable storage, e.g.USB device.
|
| + removable
|
| + };
|
| +
|
| + dictionary StorageUnitInfo {
|
| + // The unique id of the storage unit.
|
| + DOMString id;
|
| + // The type of storage device. The value is one of the constants defined
|
| + // for this type.
|
| + StorageUnitType type;
|
| + // The total amount of the storage space, in bytes.
|
| + double capacity;
|
| + // The available amount of the storage space, in bytes.
|
| + double availableCapacity;
|
| + };
|
| +
|
| + dictionary StorageChangeInfo {
|
| + // The uniue id of the storage unit already changed.
|
| + DOMString id;
|
| + // The new value of the available capacity.
|
| + double availableCapacity;
|
| + };
|
| +
|
| + callback StorageInfoCallback = void (StorageUnitInfo[] info);
|
| +
|
| + interface Functions {
|
| + // Get the storage information from the system. The argument passed to the
|
| + // callback is an array of StorageUnitInfo objects.
|
| + static void get(StorageInfoCallback callback);
|
| + };
|
| +
|
| + interface Events {
|
| + // Fired when the storage information is updated.
|
| + // |info| : The changed information for the specified storage unit
|
| + static void onAvailableCapacityChanged(StorageChangeInfo info);
|
| + };
|
| +
|
| +};
|
| +
|
|
|