mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-28 16:20:52 +00:00
Fix cursor adjustment in replace()
This commit is contained in:
parent
5054ed320e
commit
ab26581b2e
Notes:
Roan Kattouw
2012-03-08 23:21:28 +00:00
|
@ -461,7 +461,7 @@ ve.dm.TransactionProcessor.prototype.replace = function( op, invert ) {
|
||||||
|
|
||||||
// Update the linear model
|
// Update the linear model
|
||||||
ve.batchedSplice( this.model.data, this.cursor, remove.length, replacement );
|
ve.batchedSplice( this.model.data, this.cursor, remove.length, replacement );
|
||||||
this.cursor += replacement.length - remove.length;
|
this.cursor += replacement.length;
|
||||||
|
|
||||||
// TODO sync the tree too
|
// TODO sync the tree too
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue