diff --git a/lib/client/editor.js b/lib/client/editor.js index cf0237a6..0564370c 100644 --- a/lib/client/editor.js +++ b/lib/client/editor.js @@ -70,21 +70,20 @@ CloudCommander.Editor.CodeMirror = { lLeft && (lLeft.className = 'panel hidden'); - var lCodeMirror = CodeMirror(lCloudEditor,{ - mode : "xml", - htmlMode : true, - theme : 'night', - lineNumbers : true, - //переносим длинные строки - lineWrapping: true, - extraKeys: { - //Сохранение - "Esc": this.hide(this) - } + CodeMirror(lCloudEditor,{ + mode : "xml", + htmlMode : true, + theme : 'night', + lineNumbers : true, + //переносим длинные строки + lineWrapping: true, + autofocus : true, + extraKeys: { + //Сохранение + "Esc": this.hide(this) + } }); - - lCodeMirror.setCursor({line:1,ch:1}); - + lCloudEditor && (lCloudEditor.className = '');