38 if ( $linenumber & 1 ) {
39 $classes[] =
'mw-line-odd';
41 $classes[] =
'mw-line-even';
47 if ( $this->watchlist ) {
48 $classes[] = Sanitizer::escapeClass(
'watchlist-' .
49 $rc->mAttribs[
'rc_namespace'] .
'-' . $rc->mAttribs[
'rc_title'] );
56 if ( !Hooks::run(
'OldChangesListRecentChangesLine',
66 $attribs[
'class'] = implode(
' ', $classes );
68 return $dateheader . Html::rawElement(
'li',
$attribs,
$html ) .
"\n";
82 if ( $rc->mAttribs[
'rc_log_type'] ) {
83 $logtitle = SpecialPage::getTitleFor(
'Log', $rc->mAttribs[
'rc_log_type'] );
84 $this->
insertLog(
$html, $logtitle, $rc->mAttribs[
'rc_log_type'] );
86 'bot' => $rc->mAttribs[
'rc_bot'] ],
'' );
87 if ( $flags !==
'' ) {
88 $html .=
' ' . $flags;
91 } elseif ( $rc->mAttribs[
'rc_namespace'] ==
NS_SPECIAL ) {
93 if ( $name ==
'Log' ) {
99 # M, N, b and ! (minor, new, bot and unpatrolled)
102 'newpage' => $rc->mAttribs[
'rc_type'] ==
RC_NEW,
103 'minor' => $rc->mAttribs[
'rc_minor'],
104 'unpatrolled' => $unpatrolled,
105 'bot' => $rc->mAttribs[
'rc_bot']
113 # Bytes added or removed
114 if ( $this->
getConfig()->
get(
'RCShowChangedSize' ) ) {
117 $html .= $cd .
' <span class="mw-changeslist-separator">. .</span> ';
121 if ( $rc->mAttribs[
'rc_type'] ==
RC_LOG ) {
128 # LTR/RTL direction mark
140 # How many users watch this page
141 if ( $rc->numberofWatchingusers > 0 ) {
145 $html = Html::rawElement(
'span', [
146 'class' =>
'mw-changeslist-line-inner',
147 'data-target-page' => $rc->getTitle(),
149 if ( is_callable( $this->changeLinePrefixer ) ) {
150 $prefix = call_user_func( $this->changeLinePrefixer, $rc, $this,
false );
151 $html = Html::rawElement(
'span', [
'class' =>
'mw-changeslist-line-prefix' ], $prefix ) .
$html;
wfArrayFilterByKey(array $arr, callable $callback)
Like array_filter with ARRAY_FILTER_USE_KEY, but works pre-5.6.
recentChangesFlags( $flags, $nothing=' ')
Returns the appropriate flags for new page, minor change and patrolling.
formatCharacterDifference(RecentChange $old, RecentChange $new=null)
Format the character difference of one or several changes.
insertDateHeader(&$s, $rc_timestamp)
insertRollback(&$s, &$rc)
Inserts a rollback link.
showAsUnpatrolled(RecentChange $rc)
getDataAttributes(RecentChange $rc)
Get recommended data attributes for a change line.
numberofWatchingusers( $count)
Returns the string which indicates the number of watching users.
getHTMLClasses( $rc, $watched)
Get an array of default HTML class attributes for the change.
insertLog(&$s, $title, $logtype)
getArticleLink(&$rc, $unpatrolled, $watched)
insertUserRelatedLinks(&$s, &$rc)
Insert links to user page, user talk page and eventually a blocking link.
insertLogEntry( $rc)
Insert a formatted action.
insertTags(&$s, &$rc, &$classes)
insertComment( $rc)
Insert a formatted comment.
insertExtra(&$s, &$rc, &$classes)
isCategorizationWithoutRevision( $rcObj)
Determines whether a revision is linked to this change; this may not be the case when the categorizat...
insertDiffHist(&$s, &$rc, $unpatrolled=null)
insertTimestamp(&$s, $rc)
Insert time timestamp string from $rc into $s.
formatChangeLine(RecentChange $rc, array &$classes, $watched)
recentChangesLine(&$rc, $watched=false, $linenumber=null)
Format a line using the old system (aka without any javascript).
Utility class for creating new RC entries.
static resolveAlias( $alias)
Given a special page name with a possible subpage, return an array where the first element is the spe...
deferred txt A few of the database updates required by various functions here can be deferred until after the result page is displayed to the user For updating the view updating the linked to tables after a etc PHP does not yet have any way to tell the server to actually return and disconnect while still running these but it might have such a feature in the future We handle these by creating a deferred update object and putting those objects on a global list
null means default in associative array with keys and values unescaped Should be merged with default with a value of false meaning to suppress the attribute in associative array with keys and values unescaped noclasses just before the function returns a value If you return an< a > element with HTML attributes $attribs and contents $html will be returned If you return $ret will be returned and may include noclasses & $html
null means default in associative array with keys and values unescaped Should be merged with default with a value of false meaning to suppress the attribute in associative array with keys and values unescaped noclasses just before the function returns a value If you return an< a > element with HTML attributes $attribs and contents $html will be returned If you return $ret will be returned and may include noclasses after processing & $attribs