r78131 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r78130‎ | r78131 | r78132 >
Date:18:24, 9 December 2010
Author:yaron
Status:deferred
Tags:
Comment:
Replaced $sfgShowOnSelectCalls with $sfgShowOnSelect; removed $sfgJSValidationCalls, $sfgRemoverButtons, $sfgComboBoxInputs, $sfgAutogrowInputs and $sfgFancyBoxInputs global variables.
Modified paths:
  • /trunk/extensions/SemanticForms/includes/SF_FormUtils.php (modified) (history)
  • /trunk/extensions/SemanticForms/includes/SF_Settings.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticForms/includes/SF_FormUtils.php
@@ -10,24 +10,20 @@
1111
1212 class SFFormUtils {
1313 static function setGlobalJSVariables( &$vars ) {
14 - global $sfgAdderButtons, $sfgRemoverButtons;
 14+ global $sfgAdderButtons;
1515 global $sfgAutocompleteMappings, $sfgAutocompleteDataTypes, $sfgAutocompleteValues;
1616 global $sfgAutocompleteOnAllChars;
17 - global $sfgComboBoxInputs, $sfgAutogrowInputs, $sfgFancyBoxInputs;
18 - global $sfgJSValidationCalls, $sfgShowOnSelectCalls;
 17+ global $sfgShowOnSelect;
1918
2019 $vars['sfgRemoveText'] = wfMsg( 'sf_formedit_remove' );
2120 $vars['sfgAdderButtons'] = $sfgAdderButtons;
22 - $vars['sfgRemoverButtons'] = $sfgRemoverButtons;
2321 $vars['autocompleteOnAllChars'] = $sfgAutocompleteOnAllChars;
2422 // variables that are associative arrays need to be cast as
2523 // objects, to work with MW 1.15 and earlier
2624 $vars['sfgAutocompleteMappings'] = (object)$sfgAutocompleteMappings;
2725 $vars['sfgAutocompleteValues'] = (object)$sfgAutocompleteValues;
2826 $vars['sfgAutocompleteDataTypes'] = (object)$sfgAutocompleteDataTypes;
29 - $vars['sfgComboBoxInputs'] = $sfgComboBoxInputs;
30 - $vars['sfgAutogrowInputs'] = $sfgAutogrowInputs;
31 - $vars['sfgFancyBoxInputs'] = $sfgFancyBoxInputs;
 27+ $vars['sfgShowOnSelect'] = (object)$sfgShowOnSelect;
3228 $vars['sfgFormErrorsHeader'] = wfMsg( 'sf_formerrors_header' );
3329 $vars['sfgBlankErrorStr'] = wfMsg( 'sf_blank_error' );
3430 $vars['sfgBadURLErrorStr'] = wfMsg( 'sf_bad_url_error' );
@@ -35,8 +31,6 @@
3632 $vars['sfgBadNumberErrorStr'] = wfMsg( 'sf_bad_number_error' );
3733 $vars['sfgBadIntegerErrorStr'] = wfMsg( 'sf_bad_integer_error' );
3834 $vars['sfgBadDateErrorStr'] = wfMsg( 'sf_bad_date_error' );
39 - $vars['sfgJSValidationCalls'] = $sfgJSValidationCalls;
40 - $vars['sfgShowOnSelectCalls'] = $sfgShowOnSelectCalls;
4135 return true;
4236 }
4337
Index: trunk/extensions/SemanticForms/includes/SF_Settings.php
@@ -116,12 +116,7 @@
117117 # Global variables for Javascript
118118 # ##
119119 $sfgAdderButtons = array();
120 -$sfgRemoverButtons = array();
121 -$sfgShowOnSelectCalls = array();
122 -$sfgJSValidationCalls = array();
 120+$sfgShowOnSelect = array();
123121 $sfgAutocompleteMappings = array();
124122 $sfgAutocompleteDataTypes = array();
125123 $sfgAutocompleteValues = array();
126 -$sfgComboBoxInputs = array();
127 -$sfgAutogrowInputs = array();
128 -$sfgFancyBoxInputs = array();

Status & tagging log