|
|
@ -37,7 +37,6 @@ module.exports = fileExplorer |
|
|
|
|
|
|
|
|
|
|
|
function fileExplorer (appAPI, files) { |
|
|
|
function fileExplorer (appAPI, files) { |
|
|
|
var fileEvents = files.event |
|
|
|
var fileEvents = files.event |
|
|
|
var appUI = appAPI.ui |
|
|
|
|
|
|
|
var tv = new Treeview({ |
|
|
|
var tv = new Treeview({ |
|
|
|
extractData: function (value, tree, key) { |
|
|
|
extractData: function (value, tree, key) { |
|
|
|
var newValue = {} |
|
|
|
var newValue = {} |
|
|
@ -76,10 +75,8 @@ function fileExplorer (appAPI, files) { |
|
|
|
</span> |
|
|
|
</span> |
|
|
|
` |
|
|
|
` |
|
|
|
|
|
|
|
|
|
|
|
appUI.register('fileChanged', (changedFiles) => { |
|
|
|
appAPI.event.register('currentFileChanged', (newFile) => { |
|
|
|
if (changedFiles[0] === 'currentFile') { |
|
|
|
fileFocus(newFile) |
|
|
|
fileFocus(files.get('currentFile')) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}) |
|
|
|
}) |
|
|
|
fileEvents.register('fileRemoved', fileRemoved) |
|
|
|
fileEvents.register('fileRemoved', fileRemoved) |
|
|
|
fileEvents.register('fileRenamed', fileRenamed) |
|
|
|
fileEvents.register('fileRenamed', fileRenamed) |
|
|
|