| 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 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 */ | 119 */ |
| 120 this.selectionHandler_ = null; | 120 this.selectionHandler_ = null; |
| 121 | 121 |
| 122 /** | 122 /** |
| 123 * UI management class of file manager. | 123 * UI management class of file manager. |
| 124 * @type {FileManagerUI} | 124 * @type {FileManagerUI} |
| 125 * @private | 125 * @private |
| 126 */ | 126 */ |
| 127 this.ui_ = null; | 127 this.ui_ = null; |
| 128 | 128 |
| 129 /** |
| 130 * @private {analytics.Tracker} |
| 131 */ |
| 132 this.tracker_ = null; |
| 133 |
| 129 // -------------------------------------------------------------------------- | 134 // -------------------------------------------------------------------------- |
| 130 // Parameters determining the type of file manager. | 135 // Parameters determining the type of file manager. |
| 131 | 136 |
| 132 /** | 137 /** |
| 133 * Dialog type of this window. | 138 * Dialog type of this window. |
| 134 * @type {DialogType} | 139 * @type {DialogType} |
| 135 */ | 140 */ |
| 136 this.dialogType = DialogType.FULL_PAGE; | 141 this.dialogType = DialogType.FULL_PAGE; |
| 137 | 142 |
| 138 /** | 143 /** |
| (...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 445 function(enabled) { | 450 function(enabled) { |
| 446 if (enabled) { | 451 if (enabled) { |
| 447 this.importController_ = new importer.ImportController( | 452 this.importController_ = new importer.ImportController( |
| 448 new importer.RuntimeControllerEnvironment( | 453 new importer.RuntimeControllerEnvironment( |
| 449 this, | 454 this, |
| 450 this.selectionHandler_), | 455 this.selectionHandler_), |
| 451 /** @type {!importer.MediaScanner} */ ( | 456 /** @type {!importer.MediaScanner} */ ( |
| 452 this.mediaScanner_), | 457 this.mediaScanner_), |
| 453 /** @type {!importer.ImportRunner} */ ( | 458 /** @type {!importer.ImportRunner} */ ( |
| 454 this.mediaImportHandler_), | 459 this.mediaImportHandler_), |
| 455 new importer.RuntimeCommandWidget()); | 460 new importer.RuntimeCommandWidget(), |
| 461 this.tracker_); |
| 456 } | 462 } |
| 457 }.bind(this)); | 463 }.bind(this)); |
| 458 | 464 |
| 459 assert(this.fileFilter_); | 465 assert(this.fileFilter_); |
| 460 assert(this.namingController_); | 466 assert(this.namingController_); |
| 461 assert(this.appStateController_); | 467 assert(this.appStateController_); |
| 462 assert(this.taskController_); | 468 assert(this.taskController_); |
| 463 this.mainWindowComponent_ = new MainWindowComponent( | 469 this.mainWindowComponent_ = new MainWindowComponent( |
| 464 this.dialogType, | 470 this.dialogType, |
| 465 this.ui_, | 471 this.ui_, |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 646 loadTimeData.data = this.backgroundPage_.background.stringData; | 652 loadTimeData.data = this.backgroundPage_.background.stringData; |
| 647 if (util.runningInBrowser()) | 653 if (util.runningInBrowser()) |
| 648 this.backgroundPage_.registerDialog(window); | 654 this.backgroundPage_.registerDialog(window); |
| 649 this.fileOperationManager_ = | 655 this.fileOperationManager_ = |
| 650 this.backgroundPage_.background.fileOperationManager; | 656 this.backgroundPage_.background.fileOperationManager; |
| 651 this.mediaImportHandler_ = | 657 this.mediaImportHandler_ = |
| 652 this.backgroundPage_.background.mediaImportHandler; | 658 this.backgroundPage_.background.mediaImportHandler; |
| 653 this.mediaScanner_ = | 659 this.mediaScanner_ = |
| 654 this.backgroundPage_.background.mediaScanner; | 660 this.backgroundPage_.background.mediaScanner; |
| 655 this.historyLoader_ = this.backgroundPage_.background.historyLoader; | 661 this.historyLoader_ = this.backgroundPage_.background.historyLoader; |
| 662 this.tracker_ = this.backgroundPage_.background.tracker; |
| 656 callback(); | 663 callback(); |
| 657 }.bind(this)); | 664 }.bind(this)); |
| 658 }.bind(this))); | 665 }.bind(this))); |
| 659 }; | 666 }; |
| 660 | 667 |
| 661 /** | 668 /** |
| 662 * Initializes the VolumeManager instance. | 669 * Initializes the VolumeManager instance. |
| 663 * @param {function()} callback Completion callback. | 670 * @param {function()} callback Completion callback. |
| 664 * @private | 671 * @private |
| 665 */ | 672 */ |
| (...skipping 648 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1314 out += this.initializeQueue_.pendingTasks[key].toString() + '\n'; | 1321 out += this.initializeQueue_.pendingTasks[key].toString() + '\n'; |
| 1315 }.bind(this)); | 1322 }.bind(this)); |
| 1316 | 1323 |
| 1317 out += '2. VolumeManagerWrapper\n' + | 1324 out += '2. VolumeManagerWrapper\n' + |
| 1318 this.volumeManager_.toString() + '\n'; | 1325 this.volumeManager_.toString() + '\n'; |
| 1319 | 1326 |
| 1320 out += 'End of debug information.'; | 1327 out += 'End of debug information.'; |
| 1321 console.log(out); | 1328 console.log(out); |
| 1322 }; | 1329 }; |
| 1323 })(); | 1330 })(); |
| OLD | NEW |