| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 // fileManagerPrivate API. | 5 // fileManagerPrivate API. |
| 6 // This is a private API used by the file browser of ChromeOS. | 6 // This is a private API used by the file browser of ChromeOS. |
| 7 [platforms=("chromeos"), | 7 [platforms=("chromeos"), |
| 8 implemented_in="chrome/browser/chromeos/extensions/file_manager/file_manager_pr
ivate_api_functions.h"] | 8 implemented_in="chrome/browser/chromeos/extensions/file_manager/file_manager_pr
ivate_api_functions.h"] |
| 9 namespace fileManagerPrivate { | 9 namespace fileManagerPrivate { |
| 10 // Type of the mounted volume. | 10 // Type of the mounted volume. |
| (...skipping 470 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 481 | 481 |
| 482 // |fileSystem| A DOMFileSystem instance for local file system access. null if | 482 // |fileSystem| A DOMFileSystem instance for local file system access. null if |
| 483 // the caller has no appropriate permissions. | 483 // the caller has no appropriate permissions. |
| 484 callback RequestFileSystemCallback = void(optional object fileSystem); | 484 callback RequestFileSystemCallback = void(optional object fileSystem); |
| 485 | 485 |
| 486 // |entryProperties| A dictionary containing properties of the requested | 486 // |entryProperties| A dictionary containing properties of the requested |
| 487 // entries. | 487 // entries. |
| 488 callback GetEntryPropertiesCallback = | 488 callback GetEntryPropertiesCallback = |
| 489 void(EntryProperties[] entryProperties); | 489 void(EntryProperties[] entryProperties); |
| 490 | 490 |
| 491 // |localFilePaths| An array of the local file paths for the requested files, | |
| 492 // one entry for each file in fileUrls. | |
| 493 callback GetDriveFilesCallback = void(DOMString[] localFilePaths); | |
| 494 | |
| 495 // |sourcePath| Source path of the mount. | 491 // |sourcePath| Source path of the mount. |
| 496 callback AddMountCallback = void(DOMString sourcePath); | 492 callback AddMountCallback = void(DOMString sourcePath); |
| 497 | 493 |
| 498 // |volumeMetadataList| The list of VolumeMetadata representing mounted volumes. | 494 // |volumeMetadataList| The list of VolumeMetadata representing mounted volumes. |
| 499 callback GetVolumeMetadataListCallback = | 495 callback GetVolumeMetadataListCallback = |
| 500 void(VolumeMetadata[] volumeMetadataList); | 496 void(VolumeMetadata[] volumeMetadataList); |
| 501 | 497 |
| 502 // |fileTransferCancelStatuses| The list of FileTransferCancelStatus. | 498 // |fileTransferCancelStatuses| The list of FileTransferCancelStatus. |
| 503 callback CancelFileTransfersCallback = | 499 callback CancelFileTransfersCallback = |
| 504 void(FileTransferCancelStatus[] fileTransferCancelStatuses); | 500 void(FileTransferCancelStatus[] fileTransferCancelStatuses); |
| (...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 641 | 637 |
| 642 // Pins/unpins a Drive file in the cache. | 638 // Pins/unpins a Drive file in the cache. |
| 643 // |fileUrl| URL of a file to pin/unpin. | 639 // |fileUrl| URL of a file to pin/unpin. |
| 644 // |pin| Pass true to pin the file. | 640 // |pin| Pass true to pin the file. |
| 645 // |callback| Completion callback. $(ref:runtime.lastError) will be set if | 641 // |callback| Completion callback. $(ref:runtime.lastError) will be set if |
| 646 // there was an error. | 642 // there was an error. |
| 647 static void pinDriveFile(DOMString fileUrl, | 643 static void pinDriveFile(DOMString fileUrl, |
| 648 boolean pin, | 644 boolean pin, |
| 649 optional SimpleCallback callback); | 645 optional SimpleCallback callback); |
| 650 | 646 |
| 651 // Get Drive files. | |
| 652 // |fileUrls| Array of Drive file URLs to get. | |
| 653 // |callback| | |
| 654 static void getDriveFiles(DOMString[] fileUrls, | |
| 655 GetDriveFilesCallback callback); | |
| 656 | |
| 657 // Resolves file entries in the isolated file system and returns corresponding | 647 // Resolves file entries in the isolated file system and returns corresponding |
| 658 // entries in the external file system mounted to Chrome OS file manager | 648 // entries in the external file system mounted to Chrome OS file manager |
| 659 // backend. If resolving entry fails, the entry will be just ignored and the | 649 // backend. If resolving entry fails, the entry will be just ignored and the |
| 660 // corresponding entry does not appear in the result. | 650 // corresponding entry does not appear in the result. |
| 661 [nocompile] | 651 [nocompile] |
| 662 static void resolveIsolatedEntries( | 652 static void resolveIsolatedEntries( |
| 663 [instanceOf=FileEntry] object[] entries, | 653 [instanceOf=FileEntry] object[] entries, |
| 664 ResolveEntriesCallback callback); | 654 ResolveEntriesCallback callback); |
| 665 | 655 |
| 666 // Mount a resource or a file. | 656 // Mount a resource or a file. |
| (...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 816 | 806 |
| 817 static void onPreferencesChanged(); | 807 static void onPreferencesChanged(); |
| 818 | 808 |
| 819 static void onDriveConnectionStatusChanged(); | 809 static void onDriveConnectionStatusChanged(); |
| 820 | 810 |
| 821 static void onDeviceChanged(DeviceEvent event); | 811 static void onDeviceChanged(DeviceEvent event); |
| 822 | 812 |
| 823 static void onDriveSyncError(DriveSyncErrorEvent event); | 813 static void onDriveSyncError(DriveSyncErrorEvent event); |
| 824 }; | 814 }; |
| 825 }; | 815 }; |
| OLD | NEW |