Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 'use strict'; | 5 'use strict'; |
| 6 | 6 |
| 7 // If directory files changes too often, don't rescan directory more than once | 7 // If directory files changes too often, don't rescan directory more than once |
| 8 // per specified interval | 8 // per specified interval |
| 9 var SIMULTANEOUS_RESCAN_INTERVAL = 1000; | 9 var SIMULTANEOUS_RESCAN_INTERVAL = 1000; |
| 10 // Used for operations that require almost instant rescan. | 10 // Used for operations that require almost instant rescan. |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 102 * @private | 102 * @private |
| 103 */ | 103 */ |
| 104 DirectoryModel.fakeDriveRecentEntry_ = { | 104 DirectoryModel.fakeDriveRecentEntry_ = { |
| 105 fullPath: RootDirectory.DRIVE_RECENT, | 105 fullPath: RootDirectory.DRIVE_RECENT, |
| 106 isDirectory: true | 106 isDirectory: true |
| 107 }; | 107 }; |
| 108 | 108 |
| 109 /** | 109 /** |
| 110 * List of fake entries for special searches. | 110 * List of fake entries for special searches. |
| 111 * TODO(haruki): Add the entry for "Recent". | 111 * TODO(haruki): Add the entry for "Recent". |
| 112 * TODO(hirono): Bring back the entry for "Offline". http://crbug.com/238545 | |
| 113 * | 112 * |
| 114 * @type {Array.<Object>} | 113 * @type {Array.<Object>} |
| 115 * @const | 114 * @const |
| 116 */ | 115 */ |
| 117 DirectoryModel.FAKE_DRIVE_SPECIAL_SEARCH_ENTRIES = | 116 DirectoryModel.FAKE_DRIVE_SPECIAL_SEARCH_ENTRIES = |
|
yoshiki
2013/05/24 14:39:48
nit: It's not your fault, but could you change the
hirono
2013/05/27 01:07:48
Done.
| |
| 118 [DirectoryModel.fakeDriveSharedWithMeEntry_, | 117 [DirectoryModel.fakeDriveSharedWithMeEntry_, |
| 119 DirectoryModel.fakeDriveRecentEntry_]; | 118 DirectoryModel.fakeDriveRecentEntry_, |
| 119 DirectoryModel.fakeDriveOfflineEntry_]; | |
| 120 | 120 |
| 121 /** | 121 /** |
| 122 * DirectoryModel extends cr.EventTarget. | 122 * DirectoryModel extends cr.EventTarget. |
| 123 */ | 123 */ |
| 124 DirectoryModel.prototype.__proto__ = cr.EventTarget.prototype; | 124 DirectoryModel.prototype.__proto__ = cr.EventTarget.prototype; |
| 125 | 125 |
| 126 /** | 126 /** |
| 127 * Enqueues an asynchronous closure. Guarantees that the closured are called | 127 * Enqueues an asynchronous closure. Guarantees that the closured are called |
| 128 * sequentially in order they are enqueued. Each of the closures added to the | 128 * sequentially in order they are enqueued. Each of the closures added to the |
| 129 * queue must call a callback once handling is completed. | 129 * queue must call a callback once handling is completed. |
| (...skipping 1411 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1541 }.bind(this)); | 1541 }.bind(this)); |
| 1542 } | 1542 } |
| 1543 }; | 1543 }; |
| 1544 | 1544 |
| 1545 /** | 1545 /** |
| 1546 * @return {DirectoryEntry} Current watched directory entry. | 1546 * @return {DirectoryEntry} Current watched directory entry. |
| 1547 */ | 1547 */ |
| 1548 FileWatcher.prototype.getWatchedDirectoryEntry = function() { | 1548 FileWatcher.prototype.getWatchedDirectoryEntry = function() { |
| 1549 return this.watchedDirectoryEntry_; | 1549 return this.watchedDirectoryEntry_; |
| 1550 }; | 1550 }; |
| OLD | NEW |