X-Git-Url: https://git.mdrn.pl/fnpeditor.git/blobdiff_plain/c2f61b78499f7c1f4f722ef4a4b5514c95598505..50cc0c32bb9b2322e3f25be4803ad1adbf1d92a6:/modules/documentCanvas/canvas/documentElement.js diff --git a/modules/documentCanvas/canvas/documentElement.js b/modules/documentCanvas/canvas/documentElement.js index 7e5824b..0309136 100644 --- a/modules/documentCanvas/canvas/documentElement.js +++ b/modules/documentCanvas/canvas/documentElement.js @@ -143,14 +143,14 @@ DocumentNodeElement.prototype = new DocumentElement(); $.extend(DocumentNodeElement.prototype, { append: function(params) { - manipulate(this, params, 'append'); + return manipulate(this, params, 'append'); }, before: function(params) { - manipulate(this, params, 'before'); + return manipulate(this, params, 'before'); }, after: function(params) { - manipulate(this, params, 'after'); + return manipulate(this, params, 'after'); }, children: function() { var toret = []; @@ -341,6 +341,8 @@ $.extend(DocumentTextElement.prototype, { succeedingChildren.forEach(function(child) { newElement.append(child); }); + + return {first: parentElement, second: newElement}; }, });