diff --git a/lib/ace/layer/cursor.js b/lib/ace/layer/cursor.js index 636271c3..a796c84a 100644 --- a/lib/ace/layer/cursor.js +++ b/lib/ace/layer/cursor.js @@ -59,12 +59,7 @@ var Cursor = function(parentEl) { this.setCursor = function(position, overwrite) { this.position = position; - - if (overwrite) { - dom.addCssClass(this.cursor, "ace_overwrite"); - } else { - dom.removeCssClass(this.cursor, "ace_overwrite"); - } + this.overwrite = overwrite; }; this.hideCursor = function() { @@ -134,6 +129,13 @@ var Cursor = function(parentEl) { if (this.isVisible) { this.element.appendChild(this.cursor); } + + if (overwrite) { + dom.addCssClass(this.cursor, "ace_overwrite"); + } else { + dom.removeCssClass(this.cursor, "ace_overwrite"); + } + this.restartTimer(); }; diff --git a/support/pilot b/support/pilot index 6e1fbe1d..cbfac498 160000 --- a/support/pilot +++ b/support/pilot @@ -1 +1 @@ -Subproject commit 6e1fbe1dfdff64020f15cd9e23ea72b7803cf406 +Subproject commit cbfac498d30d43fdb7687d198c5b752736222c2f