| Index: chrome/browser/resources/file_manager/js/file_manager.js
|
| diff --git a/chrome/browser/resources/file_manager/js/file_manager.js b/chrome/browser/resources/file_manager/js/file_manager.js
|
| index db46de394109b0d5c0a0209c45df30a44b332d2c..4b16e3ef4774550d6c77f9c768a61089e03c1d36 100644
|
| --- a/chrome/browser/resources/file_manager/js/file_manager.js
|
| +++ b/chrome/browser/resources/file_manager/js/file_manager.js
|
| @@ -1618,6 +1618,8 @@ FileManager.prototype = {
|
| * @param {Array.<Task>} tasksList The tasks list.
|
| */
|
| FileManager.prototype.onTasksFound_ = function(selection, tasksList) {
|
| + this.taskButtons_.innerHTML = '';
|
| +
|
| for (var i = 0; i < tasksList.length; i++) {
|
| var task = tasksList[i];
|
|
|
| @@ -1653,9 +1655,10 @@ FileManager.prototype = {
|
| }
|
| this.renderTaskButton_(task);
|
| }
|
| - this.maybeRenderUnmountTask_(selection);
|
| - // This needs to be done in separate function, as check requires
|
| +
|
| + // These are done in separate functions, as the checks require
|
| // asynchronous function calls.
|
| + this.maybeRenderUnmountTask_(selection);
|
| this.maybeRenderFormattingTask_(selection);
|
| };
|
|
|
| @@ -2439,13 +2442,10 @@ FileManager.prototype = {
|
| }
|
| }
|
|
|
| - if (this.selection.fileCount > 1) {
|
| + if (this.selection.totalCount > 0) {
|
| // If more than one file is selected, make sure all checkboxes are lit
|
| // up.
|
| for (var i = 0; i < this.selection.entries.length; i++) {
|
| - if (!this.selection.entries[i].isFile)
|
| - continue;
|
| -
|
| var selectedIndex = this.selection.indexes[i];
|
| var listItem = this.currentList_.getListItemByIndex(selectedIndex);
|
| if (listItem)
|
|
|