Commit 183774f6 by Bridger Maxwell

Fixed codemirror arrowkey navigation bug.

parent d7383bf3
...@@ -1295,9 +1295,9 @@ var CodeMirror = (function() { ...@@ -1295,9 +1295,9 @@ var CodeMirror = (function() {
if (goalColumn != null) pos.x = goalColumn; if (goalColumn != null) pos.x = goalColumn;
if (unit == "page") dist = Math.min(scroller.clientHeight, window.innerHeight || document.documentElement.clientHeight); if (unit == "page") dist = Math.min(scroller.clientHeight, window.innerHeight || document.documentElement.clientHeight);
else if (unit == "line") { else if (unit == "line") {
if (dir > 0) { var line = getLine(pos.line);
dist = Math.ceil(getLine(pos.line).height); if (dir > 0 && line.widgetFunction) dist = Math.ceil(getLine(pos.line).height);
} else dist = 1; else dist = 1;
dist *= textHeight(); dist *= textHeight();
} }
var target = coordsChar(loc.x, loc.y + dist * dir + 2); 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