mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-18 17:05:17 +00:00
feature(edit) add autocomletion
This commit is contained in:
parent
fbbd741c87
commit
7b42fc260c
1 changed files with 8 additions and 3 deletions
|
|
@ -57,9 +57,6 @@ var CloudCmd, Util, DOM, CloudFunc, ace, DiffProto, diff_match_patch;
|
|||
initAce();
|
||||
}
|
||||
|
||||
if (!Modelist)
|
||||
Modelist = ace.require('ace/ext/modelist');
|
||||
|
||||
if (isDir)
|
||||
lMode = Modelist.modesByName.json.mode;
|
||||
else
|
||||
|
|
@ -151,6 +148,14 @@ var CloudCmd, Util, DOM, CloudFunc, ace, DiffProto, diff_match_patch;
|
|||
bindKey : { win: 'Ctrl-S', mac: 'Command-S' },
|
||||
exec : save
|
||||
});
|
||||
|
||||
ace.require('ace/ext/language_tools');
|
||||
Modelist = ace.require('ace/ext/modelist');
|
||||
|
||||
Ace.setOptions({
|
||||
enableBasicAutocompletion : true,
|
||||
enableSnippets : true
|
||||
});
|
||||
}
|
||||
|
||||
function save () {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue