X-Git-Url: https://git.mdrn.pl/fnpeditor.git/blobdiff_plain/8095e9703888ebe28d96a094905e43eebccb6676..da6bb077bae1614af05e0071fbfbe6ddddf4c267:/src/smartxml/smartxml.js?ds=sidebyside diff --git a/src/smartxml/smartxml.js b/src/smartxml/smartxml.js index 2d0e09f..04449cf 100644 --- a/src/smartxml/smartxml.js +++ b/src/smartxml/smartxml.js @@ -43,14 +43,6 @@ $.extend(ElementNode.prototype, DocumentNode.prototype, { return this.nativeNode.tagName.toLowerCase(); }, - append: function(documentNode) { - this._$.append(documentNode.nativeNode); - }, - - before: function(node) { - this._$.before(node.nativeNode); - }, - contents: function() { var toret = []; this._$.contents().each(function() { @@ -70,6 +62,22 @@ $.extend(ElementNode.prototype, DocumentNode.prototype, { return new ElementNode(this._$.parent()); }, + getAttr: function(name) { + return this._$.attr(name); + }, + + setAttr: function(name, value) { + this._$.attr(name, value); + }, + + append: function(documentNode) { + this._$.append(documentNode.nativeNode); + }, + + before: function(node) { + this._$.before(node.nativeNode); + }, + unwrapContent: function() { var parent = this.parent(); if(!parent)