Cenarium has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/312736

Change subject: Remove full form of ChangeTags::buildTagFilterSelector
......................................................................

Remove full form of ChangeTags::buildTagFilterSelector

This removes the full form option of ChangeTags::buildTagFilterSelector
since it is completely unused, either in core or extensions.
OOUI for tag selectors aren't implemented yet so the change in signature
shouldn't affect anything.

Change-Id: Ie97b77244b6a9596b53b562b71009686932cf97e
---
M includes/changetags/ChangeTags.php
1 file changed, 3 insertions(+), 26 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/36/312736/1

diff --git a/includes/changetags/ChangeTags.php 
b/includes/changetags/ChangeTags.php
index 6455a3a..3295789 100644
--- a/includes/changetags/ChangeTags.php
+++ b/includes/changetags/ChangeTags.php
@@ -656,17 +656,11 @@
         * Build a text box to select a change tag
         *
         * @param string $selected Tag to select by default
-        * @param bool $fullForm Affects return value, see below
-        * @param Title $title Title object to send the form to. Used only if 
$fullForm is true.
         * @param bool $ooui Use an OOUI TextInputWidget as selector instead of 
a non-OOUI input field
         *        You need to call OutputPage::enableOOUI() yourself.
-        * @return string|array
-        *        - if $fullForm is false: an array of (label, selector).
-        *        - if $fullForm is true: HTML of entire form built around the 
selector.
+        * @return array an array of (label, selector)
         */
-       public static function buildTagFilterSelector( $selected = '',
-               $fullForm = false, Title $title = null, $ooui = false
-       ) {
+       public static function buildTagFilterSelector( $selected = '', $ooui = 
false ) {
                global $wgUseTagFilter;
 
                if ( !$wgUseTagFilter || !count( self::listDefinedTags() ) ) {
@@ -697,24 +691,7 @@
                        );
                }
 
-               if ( !$fullForm ) {
-                       return $data;
-               }
-
-               $html = implode( ' ', $data );
-               $html .= "\n" .
-                       Xml::element(
-                               'input',
-                               [ 'type' => 'submit', 'value' => wfMessage( 
'tag-filter-submit' )->text() ]
-                       );
-               $html .= "\n" . Html::hidden( 'title', 
$title->getPrefixedText() );
-               $html = Xml::tags(
-                       'form',
-                       [ 'action' => $title->getLocalURL(), 'class' => 
'mw-tagfilter-form', 'method' => 'get' ],
-                       $html
-               );
-
-               return $html;
+               return $data;
        }
 
        /**

-- 
To view, visit https://gerrit.wikimedia.org/r/312736
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie97b77244b6a9596b53b562b71009686932cf97e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Cenarium <cenarium.sy...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to