r99266 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r99265‎ | r99266 | r99267 >
Date:21:35, 7 October 2011
Author:nikerabbit
Status:deferred
Tags:
Comment:
Removed unused code
Modified paths:
  • /trunk/extensions/Translate/TranslateUtils.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Translate/TranslateUtils.php
@@ -136,37 +136,9 @@
137137 return $rows;
138138 }
139139
140 - /* Some other helpers for ouput*/
 140+ /* Some other helpers for output */
141141
142142 /**
143 - * Makes a selector from name and options.
144 - * @param $name \string
145 - * @param $options \list{String} Html \<option> elements.
146 - * @return \string Html.
147 - */
148 - public static function selector( $name, $options ) {
149 - return Xml::tags( 'select', array( 'name' => $name, 'id' => $name ), $options );
150 - }
151 -
152 - /**
153 - * Makes a selector from name and options.
154 - * @param $name \string
155 - * @param $items \list{String} The name and value of options.
156 - * @param $selected \string The default selected value.
157 - * @return \string Html.
158 - */
159 - public static function simpleSelector( $name, $items, $selected ) {
160 - $options = array();
161 -
162 - foreach ( $items as $item ) {
163 - $item = strval( $item );
164 - $options[] = Xml::option( $item, $item, $item === $selected );
165 - }
166 -
167 - return self::selector( $name, implode( "\n", $options ) );
168 - }
169 -
170 - /**
171143 * Returns a localised language name.
172144 * @param $code \string Language code.
173145 * @param $native \string Use only native names.

Status & tagging log