From: Raimond Spekking Date: Tue, 27 Oct 2009 17:36:26 +0000 (+0000) Subject: Consistency tweak: 'show'/'hide' should be linked only like other filter panels on... X-Git-Tag: 1.31.0-rc.0~39077 X-Git-Url: http://git.cyclocoop.org//%22%22._DIR_PLUGIN_FULLCALENDAR.%22prive/themes/spip/images/event_edit.png/%22?a=commitdiff_plain;h=f98938d71f179f057bb68d2bc46e5f60a5993e78;p=lhc%2Fweb%2Fwiklou.git Consistency tweak: 'show'/'hide' should be linked only like other filter panels on RC/WL etc. --- diff --git a/includes/specials/SpecialWhatlinkshere.php b/includes/specials/SpecialWhatlinkshere.php index 6c0ceee20c..b63c0eee2a 100644 --- a/includes/specials/SpecialWhatlinkshere.php +++ b/includes/specials/SpecialWhatlinkshere.php @@ -396,6 +396,11 @@ class SpecialWhatLinksHere extends SpecialPage { return $f; } + /** + * Create filter panel + * + * @return string HTML fieldset and filter panel with the show/hide links + */ function getFilterPanel() { global $wgLang; $show = wfMsgHtml( 'show' ); @@ -408,11 +413,14 @@ class SpecialWhatLinksHere extends SpecialPage { $types = array( 'hidetrans', 'hidelinks', 'hideredirs' ); if( $this->target->getNamespace() == NS_FILE ) $types[] = 'hideimages'; + + // Combined message keys: 'whatlinkshere-hideredirs', 'whatlinkshere-hidetrans', 'whatlinkshere-hidelinks', 'whatlinkshere-hideimages' + // To be sure they will be find by grep foreach( $types as $type ) { $chosen = $this->opts->getValue( $type ); - $msg = wfMsgHtml( "whatlinkshere-{$type}", $chosen ? $show : $hide ); + $msg = $chosen ? $show : $hide; $overrides = array( $type => !$chosen ); - $links[] = $this->makeSelfLink( $msg, array_merge( $changed, $overrides ) ); + $links[] = wfMsgHtml( "whatlinkshere-{$type}", $this->makeSelfLink( $msg, array_merge( $changed, $overrides ) ) ); } return Xml::fieldset( wfMsg( 'whatlinkshere-filters' ), $wgLang->pipeList( $links ) ); }