Index: chrome/browser/resources/file_manager/js/directory_model.js |
=================================================================== |
--- chrome/browser/resources/file_manager/js/directory_model.js (revision 120559) |
+++ chrome/browser/resources/file_manager/js/directory_model.js (working copy) |
@@ -338,9 +338,15 @@ |
this.runningScan_.cancel(); |
this.pendingScan_ = null; |
+ var onDone = function() { |
+ cr.dispatchSimpleEvent(this, 'scan-completed'); |
+ callback(); |
+ }.bind(this); |
+ |
// Clear the table first. |
this.fileList_.splice(0, this.fileList_.length); |
- this.runningScan_ = this.createScanner_(this.fileList_, callback); |
+ cr.dispatchSimpleEvent(this, 'scan-started'); |
+ this.runningScan_ = this.createScanner_(this.fileList_, onDone); |
this.runningScan_.run(); |
}, |