目录
笙默考试管理系统-MyExamTest----codemirror(10)
一、 笙默考试管理系统-MyExamTest----codemirror
二、 笙默考试管理系统-MyExamTest----codemirror
三、 笙默考试管理系统-MyExamTest----codemirror
四、 笙默考试管理系统-MyExamTest----codemirror
五、 笙默考试管理系统-MyExamTest----codemirror
}
if (e.altKey) name = "Alt-" + name;
if (e.ctrlKey) name = "Ctrl-" + name;
if (e.metaKey) name = "Cmd-" + name;
if (e.shiftKey && (bound = lookupKey("Shift-" + name, options.extraKeys, options.keyMap))) {
dropShift = true;
} else {
bound = lookupKey(name, options.extraKeys, options.keyMap);
}
if (typeof bound == "string") {
if (commands.propertyIsEnumerable(bound)) bound = commands[bound];
else bound = null;
}
if (next && (bound || !isModifierKey(e))) options.keyMap = next;
if (!bound) return false;
if (dropShift) {
var prevShift = shiftSelecting;
shiftSelecting = null;
bound(instance);
shiftSelecting = prevShift;
} else bound(instance);
e_preventDefault(e);
return true;
}
var lastStoppedKey = null;
function onKeyDown(e) {
if (!focused) onFocus();
var code = e.keyCode;
// IE does strange things with escape.
if (ie && code == 27) { e.returnValue = false; }
setShift(code == 16 || e.shiftKey);
// First give onKeyEvent option a chance to handle this.
if (options.onKeyEvent && options.onKeyEvent(instance, addStop(e))) return;
var handled = handleKeyBinding(e);
if (window.opera) {
lastStoppedKey = handled ? e.keyCode : null;
// Opera has no cut event... we try to at least catch the key combo
if (!handled && (mac ? e.metaKey : e.ctrlKey) && e.keyCode == 88)
replaceSelection("");
}
}
function onKeyPress(e) {
if (window.opera && e.keyCode == lastStoppedKey) {lastStoppedKey = null; e_preventDefault(e); return;}
if (options.onKeyEvent && options.onKeyEvent(instance, addStop(e))) return;
if (window.opera && !e.which && handleKeyBinding(e)) return;
if (options.electricChars && mode.electricChars) {
var ch = String.fromCharCode(e.charCode == null ? e.keyCode : e.charCode);
if (mode.electricChars.indexOf(ch) > -1)
setTimeout(operation(function() {indentLine(sel.to.line, "smart");}), 75);
}