r92775 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r92774‎ | r92775 | r92776 >
Date:19:04, 21 July 2011
Author:inez
Status:deferred
Tags:
Comment:
Change the way how Document and Blocks are initialized. Implement many static class constructors.
Modified paths:
  • /trunk/parsers/wikidom/lib/es/es.ListBlock.js (modified) (history)
  • /trunk/parsers/wikidom/lib/es/es.ParagraphBlock.js (modified) (history)

Diff [purge]

Index: trunk/parsers/wikidom/lib/es/es.ParagraphBlock.js
@@ -16,6 +16,10 @@
1717 } );
1818 }
1919
 20+es.ParagraphBlock.newFromWikidom = function( wikidomBlock ) {
 21+ return new es.ParagraphBlock( wikidomBlock.lines );
 22+};
 23+
2024 es.ParagraphBlock.prototype.getLength = function() {
2125 return this.content.getLength();
2226 };
@@ -109,4 +113,6 @@
110114 return new es.Range( 0, this.content.getLength() );
111115 };
112116
113 -es.extend( es.ParagraphBlock, es.Block );
 117+es.Block.models['paragraph'] = es.ParagraphBlock;
 118+
 119+es.extend( es.ParagraphBlock, es.Block );
\ No newline at end of file
Index: trunk/parsers/wikidom/lib/es/es.ListBlock.js
@@ -20,4 +20,6 @@
2121 // var list = new es.List( style, items );
2222 }
2323
 24+es.Block.models['list'] = es.ListBlock;
 25+
2426 es.extend( es.ListBlock, es.Block );

Status & tagging log