mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 18:55:26 +00:00
chore(dom) uopdateCurrentInfo: es2015-ify
This commit is contained in:
parent
9e95d5fe97
commit
c334873c26
1 changed files with 13 additions and 14 deletions
|
|
@ -1,6 +1,5 @@
|
|||
/* global CloudCmd */
|
||||
/* global CloudFunc */
|
||||
/* global Util */
|
||||
|
||||
'use strict';
|
||||
|
||||
|
|
@ -8,6 +7,7 @@ const itype = require('itype/legacy');
|
|||
const rendy = require('rendy');
|
||||
const exec = require('execon');
|
||||
const jonny = require('jonny');
|
||||
const Util = require('../common/util');
|
||||
|
||||
const DOMFunc = function() {};
|
||||
|
||||
|
|
@ -1472,19 +1472,18 @@ function CmdProto() {
|
|||
|
||||
this.CurrentInfo = CurrentInfo,
|
||||
|
||||
this.updateCurrentInfo = function(currentFile) {
|
||||
var info = Cmd.CurrentInfo,
|
||||
current = currentFile || Cmd.getCurrentFile(),
|
||||
files = current.parentElement,
|
||||
panel = files.parentElement,
|
||||
|
||||
panelPassive = Cmd.getPanel({
|
||||
active: false
|
||||
}),
|
||||
|
||||
filesPassive = DOM.getFiles(panelPassive),
|
||||
|
||||
name = Cmd.getCurrentName(current);
|
||||
this.updateCurrentInfo = (currentFile) => {
|
||||
const info = Cmd.CurrentInfo;
|
||||
const current = currentFile || Cmd.getCurrentFile();
|
||||
const files = current.parentElement;
|
||||
const panel = files.parentElement;
|
||||
|
||||
const panelPassive = Cmd.getPanel({
|
||||
active: false
|
||||
});
|
||||
|
||||
const filesPassive = DOM.getFiles(panelPassive);
|
||||
const name = Cmd.getCurrentName(current);
|
||||
|
||||
info.dir = Cmd.getCurrentDirName();
|
||||
info.dirPath = Cmd.getCurrentDirPath();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue