r93302 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r93301‎ | r93302 | r93303 >
Date:19:39, 27 July 2011
Author:inez
Status:deferred
Tags:
Comment:
Implement getIndex method in ListBlockItem
Modified paths:
  • /trunk/parsers/wikidom/lib/es/es.ListBlockItem.js (modified) (history)

Diff [purge]

Index: trunk/parsers/wikidom/lib/es/es.ListBlockItem.js
@@ -30,6 +30,15 @@
3131 } );
3232 }
3333
 34+/**
 35+ * Gets the index of the item within it's list.
 36+ *
 37+ * @returns {Integer} Index of item
 38+ */
 39+es.ListBlockItem.prototype.getIndex = function() {
 40+ return this.list._list.indexOf( this );
 41+};
 42+
3443 es.ListBlockItem.prototype.getLength = function() {
3544 var length = this.content.getLength() + 1;
3645 for ( var i = 0; i < this.lists.length; i++ ) {

Status & tagging log