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 /** | 5 /** |
| 6 * FileManager constructor. | 6 * FileManager constructor. |
| 7 * | 7 * |
| 8 * FileManager objects encapsulate the functionality of the file selector | 8 * FileManager objects encapsulate the functionality of the file selector |
| 9 * dialogs, as well as the full screen file manager application (though the | 9 * dialogs, as well as the full screen file manager application (though the |
| 10 * latter is not yet implemented). | 10 * latter is not yet implemented). |
| (...skipping 789 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 800 | 800 |
| 801 /** | 801 /** |
| 802 * Handles events when import history changed. | 802 * Handles events when import history changed. |
| 803 * | 803 * |
| 804 * @param {!importer.ImportHistory.ChangedEvent} event | 804 * @param {!importer.ImportHistory.ChangedEvent} event |
| 805 * @private | 805 * @private |
| 806 */ | 806 */ |
| 807 FileManager.prototype.onHistoryChanged_ = function(event) { | 807 FileManager.prototype.onHistoryChanged_ = function(event) { |
| 808 this.tracker_.send(metrics.ImportEvents.HISTORY_CHANGED); | 808 this.tracker_.send(metrics.ImportEvents.HISTORY_CHANGED); |
| 809 | 809 |
| 810 if (!event.entry) { | |
|
mtomasz
2015/02/25 00:40:17
nit: Can we add a comment when can it happen that
Steve McKay
2015/02/25 01:51:56
Actually it should never be null. I might have add
| |
| 811 return; | |
| 812 } | |
| 813 | |
| 810 // Ignore any entry that isn't an immediate child of the | 814 // Ignore any entry that isn't an immediate child of the |
| 811 // current directory. | 815 // current directory. |
| 812 util.isChildEntry(event.entry, this.getCurrentDirectoryEntry()) | 816 util.isChildEntry(event.entry, this.getCurrentDirectoryEntry()) |
| 813 .then( | 817 .then( |
| 814 /** | 818 /** |
| 815 * @param {boolean} isChild | 819 * @param {boolean} isChild |
| 816 * @this {FileManager} | 820 * @this {FileManager} |
| 817 */ | 821 */ |
| 818 function(isChild) { | 822 function(isChild) { |
| 819 if (isChild) { | 823 if (isChild) { |
| (...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1301 out += this.initializeQueue_.pendingTasks[key].toString() + '\n'; | 1305 out += this.initializeQueue_.pendingTasks[key].toString() + '\n'; |
| 1302 }.bind(this)); | 1306 }.bind(this)); |
| 1303 | 1307 |
| 1304 out += '2. VolumeManagerWrapper\n' + | 1308 out += '2. VolumeManagerWrapper\n' + |
| 1305 this.volumeManager_.toString() + '\n'; | 1309 this.volumeManager_.toString() + '\n'; |
| 1306 | 1310 |
| 1307 out += 'End of debug information.'; | 1311 out += 'End of debug information.'; |
| 1308 console.log(out); | 1312 console.log(out); |
| 1309 }; | 1313 }; |
| 1310 })(); | 1314 })(); |
| OLD | NEW |