fnp
/
fnpeditor.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
smartxml: DocumentNode.getIndex function for syntactic sugar
[fnpeditor.git]
/
src
/
smartxml
/
smartxml.js
diff --git
a/src/smartxml/smartxml.js
b/src/smartxml/smartxml.js
index
b469068
..
b4036d3
100644
(file)
--- a/
src/smartxml/smartxml.js
+++ b/
src/smartxml/smartxml.js
@@
-78,6
+78,10
@@
$.extend(DocumentNode.prototype, {
insertion.insertsNew = true;
}
return insertion;
+ },
+
+ getIndex: function() {
+ return this.parent().indexOf(this);
}
});