Upgrade CodeMirror to 5.10.1 and now support fullscreen, jump-to-line in editor

This commit is contained in:
Wu Cheng-Han 2016-01-17 14:28:04 -06:00
parent ce65e58096
commit eaa8ccaccb
381 changed files with 6726 additions and 2636 deletions

13
public/vendor/codemirror/addon/merge/merge.js vendored Executable file → Normal file
View file

@ -5,12 +5,12 @@
(function(mod) {
if (typeof exports == "object" && typeof module == "object") // CommonJS
mod(require("../../lib/codemirror"), require("diff_match_patch"));
mod(require("../../lib/codemirror")); // Note non-packaged dependency diff_match_patch
else if (typeof define == "function" && define.amd) // AMD
define(["../../lib/codemirror", "diff_match_patch"], mod);
else // Plain browser env
mod(CodeMirror, diff_match_patch);
})(function(CodeMirror, diff_match_patch) {
mod(CodeMirror);
})(function(CodeMirror) {
"use strict";
var Pos = CodeMirror.Pos;
var svgNS = "http://www.w3.org/2000/svg";
@ -471,13 +471,10 @@
if (left) left.init(leftPane, origLeft, options);
if (right) right.init(rightPane, origRight, options);
if (options.collapseIdentical) {
updating = true;
if (options.collapseIdentical)
this.editor().operation(function() {
collapseIdenticalStretches(self, options.collapseIdentical);
});
updating = false;
}
if (options.connect == "align") {
this.aligners = [];
alignChunks(this.left || this.right, true);
@ -640,7 +637,7 @@
mark.clear();
cm.removeLineClass(from, "wrap", "CodeMirror-merge-collapsed-line");
}
widget.addEventListener("click", clear);
CodeMirror.on(widget, "click", clear);
return {mark: mark, clear: clear};
}