From: Aleksander Ɓukasz Date: Thu, 24 Oct 2013 09:32:09 +0000 (+0200) Subject: integration wip: sync canvas text editing with wlxml document instance X-Git-Url: https://git.mdrn.pl/fnpeditor.git/commitdiff_plain/a421b30397eaa30b23a389cc9018ad29bf987a28?ds=sidebyside integration wip: sync canvas text editing with wlxml document instance --- diff --git a/src/editor/modules/documentCanvas/canvas/canvas.js b/src/editor/modules/documentCanvas/canvas/canvas.js index 830db75..ed24cee 100644 --- a/src/editor/modules/documentCanvas/canvas/canvas.js +++ b/src/editor/modules/documentCanvas/canvas/canvas.js @@ -63,6 +63,9 @@ $.extend(Canvas.prototype, { } observer.observe(canvas.d[0], config); canvas.publisher('contentChanged'); + + var textElement = canvas.getDocumentElement(mutation.target); + textElement.data('wlxmlNode').setText(mutation.target.data); } }); });