From 0bea4da6238b1f46562b146b32d88fc8d8b9060a Mon Sep 17 00:00:00 2001 From: Wu Cheng-Han Date: Sat, 18 Feb 2017 20:11:57 +0800 Subject: Fix out of sync when deleting on same cursor position on several clients from: https://github.com/aullman/opentok-editor/issues/4 --- public/vendor/ot/codemirror-adapter.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'public/vendor/ot/codemirror-adapter.js') diff --git a/public/vendor/ot/codemirror-adapter.js b/public/vendor/ot/codemirror-adapter.js index d858c411..cc23be01 100755 --- a/public/vendor/ot/codemirror-adapter.js +++ b/public/vendor/ot/codemirror-adapter.js @@ -343,7 +343,9 @@ ot.CodeMirrorAdapter = (function (global) { }; CodeMirrorAdapter.prototype.applyOperation = function (operation) { - this.ignoreNextChange = true; + if (!operation.isNoop()) { + this.ignoreNextChange = true; + } CodeMirrorAdapter.applyOperationToCodeMirror(operation, this.cm); }; -- cgit v1.2.3