X-Git-Url: https://git.mdrn.pl/fnpeditor.git/blobdiff_plain/84f2fdcdf9bd8e62fbecaa9a47e7418cc8a4f858..edaa08a1858371fbdd9665a0220cb1b9732dd2dc:/src/smartxml/smartxml.js?ds=sidebyside diff --git a/src/smartxml/smartxml.js b/src/smartxml/smartxml.js index f9f78e8..cfae7c7 100644 --- a/src/smartxml/smartxml.js +++ b/src/smartxml/smartxml.js @@ -140,12 +140,9 @@ $.extend(DocumentNode.prototype, { var node = (metaData && metaData.node) ? metaData.node : this, event = new events.ChangeEvent(type, $.extend({node: node}, metaData || {})); if(type === 'nodeDetached' || this.document.containsNode(event.meta.node)) { - if(type === 'nodeMoved') { - event.meta.parent = origParent; - } this.document.trigger('change', event); } - if((type === 'nodeAdded' || type === 'nodeMoved') && !this.document.containsNode(this) && nodeWasContained) { + if(type === 'nodeAdded' && !this.document.containsNode(this) && nodeWasContained) { event = new events.ChangeEvent('nodeDetached', {node: node, parent: origParent}); this.document.trigger('change', event); }