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 485 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
496 this.directoryModel_.addEventListener('directory-changed', | 496 this.directoryModel_.addEventListener('directory-changed', |
497 this.setupCurrentDirectoryPostponed_); | 497 this.setupCurrentDirectoryPostponed_); |
498 } else { | 498 } else { |
499 this.setupCurrentDirectory_( | 499 this.setupCurrentDirectory_( |
500 invokeHandler, true /* blankWhileOpeningAFile */); | 500 invokeHandler, true /* blankWhileOpeningAFile */); |
501 } | 501 } |
502 | 502 |
503 this.summarizeSelection_(); | 503 this.summarizeSelection_(); |
504 | 504 |
505 var sortField = | 505 var sortField = |
506 window.localStorage['sort-field-' + this.dialogType_] || 'cachedMtime_'; | 506 window.localStorage['sort-field-' + this.dialogType_] || |
| 507 'modificationTime'; |
507 var sortDirection = | 508 var sortDirection = |
508 window.localStorage['sort-direction-' + this.dialogType_] || 'desc'; | 509 window.localStorage['sort-direction-' + this.dialogType_] || 'desc'; |
509 this.directoryModel_.fileList.sort(sortField, sortDirection); | 510 this.directoryModel_.fileList.sort(sortField, sortDirection); |
510 | 511 |
511 this.refocus(); | 512 this.refocus(); |
512 | 513 |
513 this.metadataProvider_ = | 514 this.metadataProvider_ = |
514 new MetadataProvider(this.filesystem_.root.toURL()); | 515 new MetadataProvider(this.filesystem_.root.toURL()); |
515 | 516 |
516 // PyAuto tests monitor this state by polling this variable | 517 // PyAuto tests monitor this state by polling this variable |
(...skipping 3813 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4330 | 4331 |
4331 handleSplitterDragEnd: function(e) { | 4332 handleSplitterDragEnd: function(e) { |
4332 Splitter.prototype.handleSplitterDragEnd.apply(this, arguments); | 4333 Splitter.prototype.handleSplitterDragEnd.apply(this, arguments); |
4333 this.ownerDocument.documentElement.classList.remove('col-resize'); | 4334 this.ownerDocument.documentElement.classList.remove('col-resize'); |
4334 } | 4335 } |
4335 }; | 4336 }; |
4336 | 4337 |
4337 customSplitter.decorate(splitterElement); | 4338 customSplitter.decorate(splitterElement); |
4338 }; | 4339 }; |
4339 })(); | 4340 })(); |
OLD | NEW |