Defer updates of remote ops until Ace has been updated
This commit is contained in:
@@ -353,7 +353,12 @@ define [
|
||||
@ranges.applyOp op, { user_id: track_changes_as }
|
||||
if old_id_seed?
|
||||
@ranges.setIdSeed(old_id_seed)
|
||||
@emit "ranges:dirty"
|
||||
if remote_op
|
||||
# With remote ops, Ace hasn't been updated when we receive this op,
|
||||
# so defer updating track changes until it has
|
||||
setTimeout () => @emit "ranges:dirty"
|
||||
else
|
||||
@emit "ranges:dirty"
|
||||
|
||||
_catchUpRanges: (changes = [], comments = []) ->
|
||||
# We've just been given the current server's ranges, but need to apply any local ops we have.
|
||||
|
||||
Reference in New Issue
Block a user