Chromium Code Reviews| Index: ui/file_manager/file_manager/background/js/media_scanner.js |
| diff --git a/ui/file_manager/file_manager/background/js/media_scanner.js b/ui/file_manager/file_manager/background/js/media_scanner.js |
| index 7c744b2e214768e5bcc90d94c3b31f1c1f8f2c6b..9f754dea53b2e8b8ac1c0a516631f6cb97757ccc 100644 |
| --- a/ui/file_manager/file_manager/background/js/media_scanner.js |
| +++ b/ui/file_manager/file_manager/background/js/media_scanner.js |
| @@ -6,21 +6,18 @@ |
| * Recursively scans through a list of given files and directories, and creates |
| * a list of media files. |
| * |
| - * @param {!Array.<!Entry>} entries A list of file and directory entries. File |
| - * entries are added directly to the media list; directory entries are |
| - * recursively traversed to find files, which are added to the media list. |
| * @constructor |
| */ |
| -function MediaScanner(entries) { |
| - /** @private {!Promise<!Array<!FileEntry>>} */ |
| - this.filesPromise_ = this.scan_(entries); |
| -} |
| +function MediaScanner() {} |
| /** |
| * Scans a list of directory and file entries, returning image and video files. |
| - * @param {!Array<!Entry>} entries |
| + * @param {!Array<!Entry>} entries A list of file and directory entries. File |
|
hirono
2014/12/04 04:44:26
!Array.<!Entry>
Ben Kwa
2014/12/04 19:53:02
Acknowledged.
|
| + * entries are added directly to the media list; directory entries are |
| + * recursively traversed to find files, which are added to the media list. |
| + * @return {!Promise<!Array<!FileEntry>>} |
|
hirono
2014/12/04 04:44:26
!Promise.<!Array.<!FileEntry>>
Ben Kwa
2014/12/04 19:53:02
Acknowledged.
|
| */ |
| -MediaScanner.prototype.scan_ = function(entries) { |
| +MediaScanner.prototype.scan = function(entries) { |
| /** |
| * Returns files and directories found under the given Entry. |
| * @param {!Entry} entry |
| @@ -56,10 +53,3 @@ MediaScanner.prototype.scan_ = function(entries) { |
| .then(flatten) |
| .then(filter); |
| }; |
| - |
| -/** |
| - * @return {!Promise<!Array<!FileEntry>>} |
| - */ |
| -MediaScanner.prototype.getFiles = function() { |
| - return this.filesPromise_; |
| -}; |