* Document ParserMakeImageParams hook
* Fix capitalization of @addtogroup in RepoGroup.php * Fix comment in SpecialRevisiondelete.php, replace xml functions from wf* to Xml::* and use __METHOD__ instead of hardcoded function name
This commit is contained in:
parent
311ca24c81
commit
664ad23883
3 changed files with 16 additions and 12 deletions
|
|
@ -802,6 +802,11 @@ $varCache: varaiable cache (array)
|
||||||
$parser: Parser object
|
$parser: Parser object
|
||||||
$limitReport: text that will be included (without comment tags)
|
$limitReport: text that will be included (without comment tags)
|
||||||
|
|
||||||
|
'ParserMakeImageParams': Called before the parser make an image link, use this to modify the parameters of the image.
|
||||||
|
$title: title object representing the file
|
||||||
|
$file: file object that will be used to create the image
|
||||||
|
&$params: 2-D array of parameters
|
||||||
|
|
||||||
'ParserTestParser': called when creating a new instance of Parser in maintenance/parserTests.inc
|
'ParserTestParser': called when creating a new instance of Parser in maintenance/parserTests.inc
|
||||||
$parser: Parser object created
|
$parser: Parser object created
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -41,8 +41,7 @@ function wfSpecialRevisiondelete( $par = null ) {
|
||||||
*/
|
*/
|
||||||
class RevisionDeleteForm {
|
class RevisionDeleteForm {
|
||||||
/**
|
/**
|
||||||
* @param Title $page
|
* @param WebRequest $request
|
||||||
* @param int $oldid
|
|
||||||
*/
|
*/
|
||||||
function __construct( $request ) {
|
function __construct( $request ) {
|
||||||
global $wgUser;
|
global $wgUser;
|
||||||
|
|
@ -83,17 +82,17 @@ class RevisionDeleteForm {
|
||||||
$wgOut->addWikiMsg( 'revdelete-text' );
|
$wgOut->addWikiMsg( 'revdelete-text' );
|
||||||
|
|
||||||
$items = array(
|
$items = array(
|
||||||
wfInputLabel( wfMsg( 'revdelete-log' ), 'wpReason', 'wpReason', 60 ),
|
Xml::inputLabel( wfMsg( 'revdelete-log' ), 'wpReason', 'wpReason', 60 ),
|
||||||
wfSubmitButton( wfMsg( 'revdelete-submit' ) ) );
|
Xml::submitButton( wfMsg( 'revdelete-submit' ) ) );
|
||||||
$hidden = array(
|
$hidden = array(
|
||||||
wfHidden( 'wpEditToken', $wgUser->editToken() ),
|
Xml::hidden( 'wpEditToken', $wgUser->editToken() ),
|
||||||
wfHidden( 'target', $this->page->getPrefixedText() ) );
|
Xml::hidden( 'target', $this->page->getPrefixedText() ) );
|
||||||
foreach( $this->revisions as $revid ) {
|
foreach( $this->revisions as $revid ) {
|
||||||
$hidden[] = wfHidden( 'oldid[]', $revid );
|
$hidden[] = Xml::hidden( 'oldid[]', $revid );
|
||||||
}
|
}
|
||||||
|
|
||||||
$special = SpecialPage::getTitleFor( 'Revisiondelete' );
|
$special = SpecialPage::getTitleFor( 'Revisiondelete' );
|
||||||
$wgOut->addHtml( wfElement( 'form', array(
|
$wgOut->addHtml( Xml::element( 'form', array(
|
||||||
'method' => 'post',
|
'method' => 'post',
|
||||||
'action' => $special->getLocalUrl( 'action=submit' ) ),
|
'action' => $special->getLocalUrl( 'action=submit' ) ),
|
||||||
null ) );
|
null ) );
|
||||||
|
|
@ -102,7 +101,7 @@ class RevisionDeleteForm {
|
||||||
foreach( $this->checks as $item ) {
|
foreach( $this->checks as $item ) {
|
||||||
list( $message, $name, $field ) = $item;
|
list( $message, $name, $field ) = $item;
|
||||||
$wgOut->addHtml( '<div>' .
|
$wgOut->addHtml( '<div>' .
|
||||||
wfCheckLabel( wfMsg( $message), $name, $name, $rev->isDeleted( $field ) ) .
|
Xml::checkLabel( wfMsg( $message), $name, $name, $rev->isDeleted( $field ) ) .
|
||||||
'</div>' );
|
'</div>' );
|
||||||
}
|
}
|
||||||
$wgOut->addHtml( '</fieldset>' );
|
$wgOut->addHtml( '</fieldset>' );
|
||||||
|
|
@ -228,7 +227,7 @@ class RevisionDeleter {
|
||||||
$this->db->update( 'revision',
|
$this->db->update( 'revision',
|
||||||
array( 'rev_deleted' => $bitfield ),
|
array( 'rev_deleted' => $bitfield ),
|
||||||
array( 'rev_id' => $rev->getId() ),
|
array( 'rev_id' => $rev->getId() ),
|
||||||
'RevisionDeleter::updateRevision' );
|
__METHOD__ );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -244,7 +243,7 @@ class RevisionDeleter {
|
||||||
'rc_comment' => ($bitfield & Revision::DELETED_COMMENT) ? wfMsg( 'rev-deleted-comment' ) : $rev->getComment() ),
|
'rc_comment' => ($bitfield & Revision::DELETED_COMMENT) ? wfMsg( 'rev-deleted-comment' ) : $rev->getComment() ),
|
||||||
array(
|
array(
|
||||||
'rc_this_oldid' => $rev->getId() ),
|
'rc_this_oldid' => $rev->getId() ),
|
||||||
'RevisionDeleter::updateRecentChanges' );
|
__METHOD__ );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Prioritized list of file repositories
|
* Prioritized list of file repositories
|
||||||
* @addtogroup filerepo
|
* @addtogroup FileRepo
|
||||||
*/
|
*/
|
||||||
class RepoGroup {
|
class RepoGroup {
|
||||||
var $localRepo, $foreignRepos, $reposInitialised = false;
|
var $localRepo, $foreignRepos, $reposInitialised = false;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue