mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-24 03:05:41 +00:00
feature(edit) show: rm value
This commit is contained in:
parent
0f55931c5d
commit
523bb11605
1 changed files with 7 additions and 12 deletions
|
|
@ -50,9 +50,8 @@ var CloudCmd, Util, DOM, CloudFunc, ace, DiffProto, diff_match_patch, Zip, MenuI
|
|||
]);
|
||||
}
|
||||
|
||||
this.show = function(value) {
|
||||
this.show = function() {
|
||||
var mode, htmlMode, jsMode, isHTML, isJS, modesByName,
|
||||
isStr = type.string(value),
|
||||
name = Info.name,
|
||||
isDir = Info.isDir;
|
||||
|
||||
|
|
@ -96,22 +95,18 @@ var CloudCmd, Util, DOM, CloudFunc, ace, DiffProto, diff_match_patch, Zip, MenuI
|
|||
setUseOfWorker(mode);
|
||||
setEmmet(isHTML);
|
||||
|
||||
Util.exec.if(isStr, function() {
|
||||
Info.getData(function(error, data) {
|
||||
var UndoManager = ace.require('ace/undomanager').UndoManager;
|
||||
|
||||
Value = data;
|
||||
|
||||
if (isJS && Session.getUseWorker())
|
||||
setJsHintConfig();
|
||||
|
||||
Ace.setValue(Value);
|
||||
CloudCmd.View.show(Element, ConfigView);
|
||||
|
||||
Session.setUndoManager(new UndoManager());
|
||||
}, function(callback) {
|
||||
Info.getData(function(error, data) {
|
||||
Value = data;
|
||||
|
||||
if (isJS && Session.getUseWorker())
|
||||
setJsHintConfig();
|
||||
|
||||
callback();
|
||||
});
|
||||
});
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue