From d487092d845839fd7c8fc33b18da026ed2f6de78 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sun, 5 Apr 2015 02:33:45 +0200 Subject: [PATCH] formatting --- .../functions/fnc_exportSettings.sqf | 4 +-- .../functions/fnc_moduleAllowConfigExport.sqf | 4 +-- .../fnc_onListBoxSettingsChanged.sqf | 28 +++++++++---------- .../functions/fnc_onServerSaveInputField.sqf | 28 +++++++++---------- .../fnc_toggleIncludeClientSettings.sqf | 4 +-- 5 files changed, 34 insertions(+), 34 deletions(-) diff --git a/addons/optionsmenu/functions/fnc_exportSettings.sqf b/addons/optionsmenu/functions/fnc_exportSettings.sqf index bb94d38db3..8718698a18 100644 --- a/addons/optionsmenu/functions/fnc_exportSettings.sqf +++ b/addons/optionsmenu/functions/fnc_exportSettings.sqf @@ -19,7 +19,7 @@ _compiledConfig = " "; { - /*_settingData = [ + /*_settingData = [ _name, _typeName, _isClientSetable, @@ -41,7 +41,7 @@ _compiledConfig = " if (GVAR(ClientSettingsExportIncluded) || !_isClientSetable) then { _value = missionNamespace getvariable [_name, _defaultValue]; if (_typeName == "STRING") then { // I dont think we have string values, but just in case - _value = format['"%1"', _value]; + _value = format['"%1"', _value]; }; _compiledConfigEntry = format [" diff --git a/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf b/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf index 1d98384a09..d756a0ef83 100644 --- a/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf +++ b/addons/optionsmenu/functions/fnc_moduleAllowConfigExport.sqf @@ -19,7 +19,7 @@ _logic = _this select 0; if (isMultiplayer) exitwith {}; if (_logic getvariable ["allowconfigurationExport", false]) then { - GVAR(serverConfigGeneration) = 1; + GVAR(serverConfigGeneration) = 1; } else { - GVAR(serverConfigGeneration) = 0; + GVAR(serverConfigGeneration) = 0; }; diff --git a/addons/optionsmenu/functions/fnc_onListBoxSettingsChanged.sqf b/addons/optionsmenu/functions/fnc_onListBoxSettingsChanged.sqf index 50b2d5302a..1543a2c8d5 100644 --- a/addons/optionsmenu/functions/fnc_onListBoxSettingsChanged.sqf +++ b/addons/optionsmenu/functions/fnc_onListBoxSettingsChanged.sqf @@ -24,18 +24,18 @@ _rightDropDownIndex = lbCurSel 400; //Index of right drop down if (_rightDropDownIndex < 0) then {_rightDropDownIndex = 0;}; switch (GVAR(optionMenu_openTab)) do { - case (MENU_TAB_OPTIONS): { - if ((_settingIndex >= 0) && (_settingIndex < (count GVAR(clientSideOptions)))) then { - _settingIndex = (GVAR(clientSideOptions) select _settingIndex) select 0; - [MENU_TAB_OPTIONS, _settingIndex, _rightDropDownIndex] call FUNC(updateSetting); - }; - [false] call FUNC(settingsMenuUpdateList); - }; - case (MENU_TAB_SERVER_OPTIONS): { - if ((_settingIndex >= 0) && (_settingIndex < (count GVAR(serverSideOptions)))) then { - _settingIndex = (GVAR(serverSideOptions) select _settingIndex) select 0; - [MENU_TAB_SERVER_OPTIONS, _settingIndex, _rightDropDownIndex] call FUNC(updateSetting); - }; - [false] call FUNC(serverSettingsMenuUpdateList); - }; + case (MENU_TAB_OPTIONS): { + if ((_settingIndex >= 0) && (_settingIndex < (count GVAR(clientSideOptions)))) then { + _settingIndex = (GVAR(clientSideOptions) select _settingIndex) select 0; + [MENU_TAB_OPTIONS, _settingIndex, _rightDropDownIndex] call FUNC(updateSetting); + }; + [false] call FUNC(settingsMenuUpdateList); + }; + case (MENU_TAB_SERVER_OPTIONS): { + if ((_settingIndex >= 0) && (_settingIndex < (count GVAR(serverSideOptions)))) then { + _settingIndex = (GVAR(serverSideOptions) select _settingIndex) select 0; + [MENU_TAB_SERVER_OPTIONS, _settingIndex, _rightDropDownIndex] call FUNC(updateSetting); + }; + [false] call FUNC(serverSettingsMenuUpdateList); + }; }; diff --git a/addons/optionsmenu/functions/fnc_onServerSaveInputField.sqf b/addons/optionsmenu/functions/fnc_onServerSaveInputField.sqf index f4dc6956c4..ca4a00891a 100644 --- a/addons/optionsmenu/functions/fnc_onServerSaveInputField.sqf +++ b/addons/optionsmenu/functions/fnc_onServerSaveInputField.sqf @@ -22,22 +22,22 @@ _settingIndex = lbCurSel 200; //Index of left list _inputText = ctrlText 414; //Index of right drop down switch (GVAR(optionMenu_openTab)) do { - case (MENU_TAB_SERVER_VALUES): { + case (MENU_TAB_SERVER_VALUES): { if ((_settingIndex >= 0) && (_settingIndex < (count GVAR(serverSideValues)))) then { - try { - _setting = (GVAR(serverSideValues) select _settingIndex); - _settingName = _setting select 0; + try { + _setting = (GVAR(serverSideValues) select _settingIndex); + _settingName = _setting select 0; - _convertedValue = switch (toUpper (_setting select 1)) do { - case "STRING": {format ['"%1"', _inputText]}; - case "ARRAY": {format [call compile "[%1]", _inputText]}; - case "SCALAR": {parseNumber _inputText;}; - default {throw "Error"}; - }; - [MENU_TAB_SERVER_VALUES, _settingName, _convertedValue] call FUNC(updateSetting); - } catch { - }; - }; + _convertedValue = switch (toUpper (_setting select 1)) do { + case "STRING": {format ['"%1"', _inputText]}; + case "ARRAY": {format [call compile "[%1]", _inputText]}; + case "SCALAR": {parseNumber _inputText;}; + default {throw "Error"}; + }; + [MENU_TAB_SERVER_VALUES, _settingName, _convertedValue] call FUNC(updateSetting); + } catch { + }; + }; [false] call FUNC(serverSettingsMenuUpdateList); }; }; diff --git a/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf b/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf index 0558c81831..5713bf98e4 100644 --- a/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf +++ b/addons/optionsmenu/functions/fnc_toggleIncludeClientSettings.sqf @@ -19,9 +19,9 @@ private "_settingsMenu"; disableSerialization; _settingsMenu = uiNamespace getVariable 'ACE_serverSettingsMenu'; if (GVAR(ClientSettingsExportIncluded)) then { - (_settingsMenu displayCtrl 1102) ctrlSetText localize ("STR_ACE_OptionsMenu_exClientSettings"); + (_settingsMenu displayCtrl 1102) ctrlSetText localize ("STR_ACE_OptionsMenu_exClientSettings"); } else { - (_settingsMenu displayCtrl 1102) ctrlSetText localize ("STR_ACE_OptionsMenu_inClientSettings"); + (_settingsMenu displayCtrl 1102) ctrlSetText localize ("STR_ACE_OptionsMenu_inClientSettings"); }; [] call FUNC(onServerSettingsMenuOpen);