r47417 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r47416‎ | r47417 | r47418 >
Date:04:39, 18 February 2009
Author:werdna
Status:deferred
Tags:
Comment:
Implement tag display for EnhancedChangesList -- TODO implement the CSS styling of tags for EnhancedChangesList. Incidentally, why do we have two methods for formatting a diff for EnhancedChangesList?
Modified paths:
  • /trunk/phase3/includes/ChangesList.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/ChangesList.php
@@ -467,6 +467,7 @@
468468 * Format a line for enhanced recentchange (aka with javascript and block of lines).
469469 */
470470 public function recentChangesLine( &$baseRC, $watched = false ) {
 471+
471472 global $wgLang, $wgContLang, $wgUser;
472473
473474 # Create a specialised object
@@ -604,6 +605,7 @@
605606 if( !isset( $this->rc_cache[$secureName] ) ) {
606607 $this->rc_cache[$secureName] = array();
607608 }
 609+
608610 array_push( $this->rc_cache[$secureName], $rc );
609611 }
610612 return $ret;
@@ -769,6 +771,8 @@
770772 # Extract fields from DB into the function scope (rc_xxxx variables)
771773 // FIXME: Would be good to replace this extract() call with something
772774 // that explicitly initializes variables.
 775+ # Classes to apply -- TODO implement
 776+ $classes = array();
773777 extract( $rcObj->mAttribs );
774778
775779 #$r .= '<tr><td valign="top">'.$this->spacerArrow();
@@ -819,6 +823,9 @@
820824 $this->insertComment( $r, $rcObj );
821825 # Rollback
822826 $this->insertRollback( $r, $rcObj );
 827+ # Tags
 828+ $this->insertTags( $r, $rcObj, $classes );
 829+
823830 # Mark revision as deleted
824831 if( !$rc_log_type && $this->isDeleted($rcObj,Revision::DELETED_TEXT) ) {
825832 $r .= ' <tt>' . wfMsgHtml( 'deletedrev' ) . '</tt>';
@@ -892,6 +899,7 @@
893900 # Extract fields from DB into the function scope (rc_xxxx variables)
894901 // FIXME: Would be good to replace this extract() call with something
895902 // that explicitly initializes variables.
 903+ $classes = array(); // TODO implement
896904 extract( $rcObj->mAttribs );
897905 $curIdEq = "curid={$rc_cur_id}";
898906
@@ -936,6 +944,8 @@
937945 }
938946 $this->insertComment( $r, $rcObj );
939947 $this->insertRollback( $r, $rcObj );
 948+ # Tags
 949+ $this->insertTags( $r, $rcObj, $classes );
940950 # Show how many people are watching this if enabled
941951 $r .= $this->numberofWatchingusers($rcObj->numberofWatchingusers);
942952

Status & tagging log