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 /** | 7 /** |
8 * This variable is checked in SelectFileDialogExtensionBrowserTest. | 8 * This variable is checked in SelectFileDialogExtensionBrowserTest. |
9 * @type {number} | 9 * @type {number} |
10 */ | 10 */ |
(...skipping 1126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1137 * Initialize the file list table or grid. | 1137 * Initialize the file list table or grid. |
1138 * | 1138 * |
1139 * @param {cr.ui.List} list The list. | 1139 * @param {cr.ui.List} list The list. |
1140 * @private | 1140 * @private |
1141 */ | 1141 */ |
1142 FileManager.prototype.initList_ = function(list) { | 1142 FileManager.prototype.initList_ = function(list) { |
1143 // Overriding the default role 'list' to 'listbox' for better accessibility | 1143 // Overriding the default role 'list' to 'listbox' for better accessibility |
1144 // on ChromeOS. | 1144 // on ChromeOS. |
1145 list.setAttribute('role', 'listbox'); | 1145 list.setAttribute('role', 'listbox'); |
1146 list.addEventListener('click', this.onDetailClick_.bind(this)); | 1146 list.addEventListener('click', this.onDetailClick_.bind(this)); |
| 1147 list.id = 'file-list'; |
1147 }; | 1148 }; |
1148 | 1149 |
1149 /** | 1150 /** |
1150 * @private | 1151 * @private |
1151 */ | 1152 */ |
1152 FileManager.prototype.onCopyProgress_ = function(event) { | 1153 FileManager.prototype.onCopyProgress_ = function(event) { |
1153 if (event.reason === 'ERROR' && | 1154 if (event.reason === 'ERROR' && |
1154 event.error.reason === 'FILESYSTEM_ERROR' && | 1155 event.error.reason === 'FILESYSTEM_ERROR' && |
1155 event.error.data.toDrive && | 1156 event.error.data.toDrive && |
1156 event.error.data.code == FileError.QUOTA_EXCEEDED_ERR) { | 1157 event.error.data.code == FileError.QUOTA_EXCEEDED_ERR) { |
(...skipping 2371 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3528 * Set the flag expressing whether the ctrl key is pressed or not. | 3529 * Set the flag expressing whether the ctrl key is pressed or not. |
3529 * @param {boolean} flag New value of the flag | 3530 * @param {boolean} flag New value of the flag |
3530 * @private | 3531 * @private |
3531 */ | 3532 */ |
3532 FileManager.prototype.setCtrlKeyPressed_ = function(flag) { | 3533 FileManager.prototype.setCtrlKeyPressed_ = function(flag) { |
3533 this.ctrlKeyPressed_ = flag; | 3534 this.ctrlKeyPressed_ = flag; |
3534 this.document_.querySelector('#drive-clear-local-cache').canExecuteChange(); | 3535 this.document_.querySelector('#drive-clear-local-cache').canExecuteChange(); |
3535 this.document_.querySelector('#drive-reload').canExecuteChange(); | 3536 this.document_.querySelector('#drive-reload').canExecuteChange(); |
3536 }; | 3537 }; |
3537 })(); | 3538 })(); |
OLD | NEW |