笙默考试管理系统-MyExamTest----codemirror(10)

笙默考试管理系统-MyExamTest----codemirror(10

目录

笙默考试管理系统-MyExamTest----codemirror(10)

一、 笙默考试管理系统-MyExamTest----codemirror

二、 笙默考试管理系统-MyExamTest----codemirror

三、 笙默考试管理系统-MyExamTest----codemirror

四、 笙默考试管理系统-MyExamTest----codemirror

五、 笙默考试管理系统-MyExamTest----codemirror

  • 笙默考试管理系统-MyExamTest----codemirror

 fastPoll();

        }

        function onKeyUp(e) {

            if (options.onKeyEvent && options.onKeyEvent(instance, addStop(e))) return;

            if (e.keyCode == 16) shiftSelecting = null;

        }

  • 笙默考试管理系统-MyExamTest----codemirror

        function onFocus() {

            if (options.readOnly) return;

            if (!focused) {

                if (options.onFocus) options.onFocus(instance);

                focused = true;

                if (wrapper.className.search(/\bCodeMirror-focused\b/) == -1)

                    wrapper.className += " CodeMirror-focused";

                if (!leaveInputAlone) resetInput(true);

            }

            slowPoll();

            restartBlink();

        }

  • 笙默考试管理系统-MyExamTest----codemirror

        function onBlur() {

            if (focused) {

                if (options.onBlur) options.onBlur(instance);

                focused = false;

                wrapper.className = wrapper.className.replace(" CodeMirror-focused", "");

            }

            clearInterval(blinker);

            setTimeout(function() {if (!focused) shiftSelecting = null;}, 150);

        }

        // Replace the range from from to to by the strings in newText.

        // Afterwards, set the selection to selFrom, selTo.

        function updateLines(from, to, newText, selFrom, selTo) {

            if (history) {

                var old = [];

                doc.iter(from.line, to.line + 1, function(line) { old.push(line.text); });

                history.addChange(from.line, newText.length, old);

                while (history.done.length > options.undoDepth) history.done.shift();

            }

  • 笙默考试管理系统-MyExamTest----codemirror

            updateLinesNoUndo(from, to, newText, selFrom, selTo);

        }

        function unredoHelper(from, to) {

            var change = from.pop();

            if (change) {

                var replaced = [], end = change.start + change.added;

                doc.iter(change.start, end, function(line) { replaced.push(line.text); });

                to.push({start: change.start, added: change.old.length, old: replaced});

                var pos = clipPos({line: change.start + change.old.length - 1,

                    ch: editEnd(replaced[replaced.length-1], change.old[change.old.length-1])});

                updateLinesNoUndo({line: change.start, ch: 0}, {line: end - 1, ch: getLine(end-1).text.length}, change.old, pos, pos);

                updateInput = true;

            }

        }

  • 笙默考试管理系统-MyExamTest----codemirror

        function undo() {unredoHelper(history.done, history.undone);}

        function redo() {unredoHelper(history.undone, history.done);}

你可能感兴趣的:(笙默考试管理系统,java)