From: Aleksander Ɓukasz Date: Tue, 13 May 2014 10:41:22 +0000 (+0200) Subject: editor: plugins/core - better selecton restore after undoing/redoing link edition... X-Git-Url: https://git.mdrn.pl/fnpeditor.git/commitdiff_plain/55dfd1283b710bfb834cd1bb56d0e65d8a89e96c?ds=sidebyside editor: plugins/core - better selecton restore after undoing/redoing link edition via link tool box --- diff --git a/src/editor/plugins/core/links/linkElement.js b/src/editor/plugins/core/links/linkElement.js index 8d280c7..ceefee1 100644 --- a/src/editor/plugins/core/links/linkElement.js +++ b/src/editor/plugins/core/links/linkElement.js @@ -63,7 +63,7 @@ _.extend(linkElement, { }, { metadata: { description: gettext('Edit link'), - fragment: doc.createFragment(doc.CaretFragment, {node: el.wlxmlNode.contents()[0], offset:0}) + fragment: doc.createFragment(doc.CaretFragment, {node: el.wlxmlNode.contents()[0], offset:offset}) }, success: function() { el.canvas.select(doc.createFragment(doc.CaretFragment, {node: el.wlxmlNode.contents()[0], offset:offset}));