- public function insertAction( &$s, &$rc ) {
- if( $rc->mAttribs['rc_type'] == RC_LOG ) {
- if( $this->isDeleted( $rc, LogPage::DELETED_ACTION ) ) {
- $s .= ' <span class="history-deleted">' . wfMsgHtml( 'rev-deleted-event' ) . '</span>';
- } else {
- $s .= ' '.LogPage::actionText( $rc->mAttribs['rc_log_type'], $rc->mAttribs['rc_log_action'],
- $rc->getTitle(), $this->getSkin(), LogPage::extractParams( $rc->mAttribs['rc_params'] ), true, true );
- }
- }
- }
-
- /** insert a formatted comment
- *
- * @param $rc RecentChange
- */
- public function insertComment( &$s, &$rc ) {
- if( $rc->mAttribs['rc_type'] != RC_MOVE && $rc->mAttribs['rc_type'] != RC_MOVE_OVER_REDIRECT ) {
- if( $this->isDeleted( $rc, Revision::DELETED_COMMENT ) ) {
- $s .= ' <span class="history-deleted">' . wfMsgHtml( 'rev-deleted-comment' ) . '</span>';
- } else {
- $s .= Linker::commentBlock( $rc->mAttribs['rc_comment'], $rc->getTitle() );
- }
- }
+ public function insertLogEntry( $rc ) {
+ $formatter = LogFormatter::newFromRow( $rc->mAttribs );
+ $mark = $this->getLang()->getDirMark();
+ return $formatter->getActionText() . " $mark" . $formatter->getComment();