From: Aleksander Ɓukasz Date: Thu, 27 Jun 2013 13:13:36 +0000 (+0200) Subject: Fixing breaking node into two X-Git-Url: https://git.mdrn.pl/fnpeditor.git/commitdiff_plain/12763ff44e918f409a0ede75a4da383d8bdc6d95 Fixing breaking node into two --- diff --git a/modules/documentCanvas/canvasManager.js b/modules/documentCanvas/canvasManager.js index b6a316e..da9b941 100644 --- a/modules/documentCanvas/canvasManager.js +++ b/modules/documentCanvas/canvasManager.js @@ -186,7 +186,7 @@ Manager.prototype.onEnterKey = function(e) { if(pos.isAtEnd) { newNode = canvasNode.create({tag: pos.parentNode.attr('wlxml-tag'), klass: pos.parentNode.attr('wlxml-class')}); - this.canvas.nodeInsertAfter({node: newNode, after: canvas.getNodeById(pos.parentNode.attr('id'))}); + this.canvas.nodeInsertAfter({node: newNode, after: this.canvas.getNodeById(pos.parentNode.attr('id'))}); } else { newNode = this.canvas.nodeSplit({node: contextNode, textNodeIdx: pos.textNodeIndex, offset: pos.textNodeOffset}); }