From 6b237ebf55e01e40070561bf46026b320222ebad Mon Sep 17 00:00:00 2001 From: Siebrand Mazeland Date: Thu, 14 Nov 2013 13:08:14 +0100 Subject: [PATCH] Update docs for files in includes/actions/ Change-Id: I99655ad3df4bc252e3c176e4f465f5ecd615c55f --- includes/actions/CreditsAction.php | 1 + includes/actions/HistoryAction.php | 35 ++++++++++++++++++++++++------ includes/actions/InfoAction.php | 1 + includes/actions/RevertAction.php | 3 +++ 4 files changed, 33 insertions(+), 7 deletions(-) diff --git a/includes/actions/CreditsAction.php b/includes/actions/CreditsAction.php index cd7eb458ee..97c160510d 100644 --- a/includes/actions/CreditsAction.php +++ b/includes/actions/CreditsAction.php @@ -127,6 +127,7 @@ class CreditsAction extends FormlessAction { $anon_ips = array(); # Sift for real versus user names + /** @var $user User */ foreach ( $contributors as $user ) { $cnt--; if ( $user->isLoggedIn() ) { diff --git a/includes/actions/HistoryAction.php b/includes/actions/HistoryAction.php index 687a4600d1..4f579c62cb 100644 --- a/includes/actions/HistoryAction.php +++ b/includes/actions/HistoryAction.php @@ -37,6 +37,9 @@ class HistoryAction extends FormlessAction { const DIR_PREV = 0; const DIR_NEXT = 1; + /** @var array Array of message keys and strings */ + public $message; + public function getName() { return 'history'; } @@ -341,14 +344,28 @@ class HistoryAction extends FormlessAction { * @ingroup Actions */ class HistoryPager extends ReverseChronologicalPager { - public $lastRow = false, $counter, $historyPage, $buttons, $conds; + /** + * @var bool|stdClass + */ + public $lastRow = false; + + public $counter, $historyPage, $buttons, $conds; + protected $oldIdChecked; + protected $preventClickjacking = false; /** * @var array */ protected $parentLens; + /** + * @param HistoryAction $historyPage + * @param string $year + * @param string $month + * @param string $tagFilter + * @param array $conds + */ function __construct( $historyPage, $year = '', $month = '', $tagFilter = '', $conds = array() ) { parent::__construct( $historyPage->getContext() ); $this->historyPage = $historyPage; @@ -397,6 +414,10 @@ class HistoryPager extends ReverseChronologicalPager { return 'rev_timestamp'; } + /** + * @param stdClass $row + * @return string + */ function formatRow( $row ) { if ( $this->lastRow ) { $latest = ( $this->counter == 1 && $this->mIsFirst ); @@ -537,14 +558,14 @@ class HistoryPager extends ReverseChronologicalPager { * * @todo document some more, and maybe clean up the code (some params redundant?) * - * @param $row Object: the database row corresponding to the previous line. - * @param $next Mixed: the database row corresponding to the next line + * @param stdObject $row The database row corresponding to the previous line. + * @param mixed $next The database row corresponding to the next line * (chronologically previous) - * @param $notificationtimestamp - * @param $latest Boolean: whether this row corresponds to the page's latest revision. - * @param $firstInList Boolean: whether this row corresponds to the first + * @param bool|string $notificationtimestamp + * @param bool $latest Whether this row corresponds to the page's latest revision. + * @param bool $firstInList Whether this row corresponds to the first * displayed on this history page. - * @return String: HTML output for the row + * @return string HTML output for the row */ function historyLine( $row, $next, $notificationtimestamp = false, $latest = false, $firstInList = false ) { diff --git a/includes/actions/InfoAction.php b/includes/actions/InfoAction.php index c97267bd1a..811e35de65 100644 --- a/includes/actions/InfoAction.php +++ b/includes/actions/InfoAction.php @@ -763,6 +763,7 @@ class InfoAction extends FormlessAction { $anon_ips = array(); # Sift for real versus user names + /** @var $user User */ foreach ( $contributors as $user ) { $page = $user->isAnon() ? SpecialPage::getTitleFor( 'Contributions', $user->getName() ) diff --git a/includes/actions/RevertAction.php b/includes/actions/RevertAction.php index e5f192970b..cdd139e734 100644 --- a/includes/actions/RevertAction.php +++ b/includes/actions/RevertAction.php @@ -48,6 +48,9 @@ class RevertAction extends Action { * @ingroup Actions */ class RevertFileAction extends FormAction { + /** + * @var OldLocalFile + */ protected $oldFile; public function getName() { -- 2.20.1