fix cursor clipping
This commit is contained in:
parent
44f2e923b4
commit
9c422423af
2 changed files with 4 additions and 4 deletions
|
|
@ -135,11 +135,11 @@ var Anchor = exports.Anchor = function(doc, row, column) {
|
||||||
|
|
||||||
this.setPosition = function(row, column) {
|
this.setPosition = function(row, column) {
|
||||||
pos = this.$clipPositionToDocument(row, column);
|
pos = this.$clipPositionToDocument(row, column);
|
||||||
if (this.row == row && this.column == column)
|
if (this.row == pos.row && this.column == pos.column)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
this.row = row;
|
this.row = pos.row;
|
||||||
this.column = column;
|
this.column = pos.column;
|
||||||
this._dispatchEvent("change");
|
this._dispatchEvent("change");
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -406,7 +406,7 @@ var Selection = function(session) {
|
||||||
this.moveCursorTo = function(row, column, preventUpdateDesiredColumn) {
|
this.moveCursorTo = function(row, column, preventUpdateDesiredColumn) {
|
||||||
this.selectionLead.setPosition(row, column);
|
this.selectionLead.setPosition(row, column);
|
||||||
if (!preventUpdateDesiredColumn)
|
if (!preventUpdateDesiredColumn)
|
||||||
this.$updateDesiredColumn(column);
|
this.$updateDesiredColumn(this.selectionLead.column);
|
||||||
};
|
};
|
||||||
|
|
||||||
}).call(Selection.prototype);
|
}).call(Selection.prototype);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue