Commit 7c7fcbde by Bridger Maxwell

Fixed codemirror arrowkey navigation bug.

parent a0af313e
......@@ -1295,9 +1295,9 @@ var CodeMirror = (function() {
if (goalColumn != null) pos.x = goalColumn;
if (unit == "page") dist = Math.min(scroller.clientHeight, window.innerHeight || document.documentElement.clientHeight);
else if (unit == "line") {
if (dir > 0) {
dist = Math.ceil(getLine(pos.line).height);
} else dist = 1;
var line = getLine(pos.line);
if (dir > 0 && line.widgetFunction) dist = Math.ceil(getLine(pos.line).height);
else dist = 1;
dist *= textHeight();
}
var target = coordsChar(loc.x, loc.y + dist * dir + 2);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment