ACE3/addons/optionsmenu/functions/fnc_onListBoxSettingsChanged.sqf
Glowbal 4f08d0d006 Merge branch 'master' into SettingsMenuImprovements
Conflicts:
	addons/optionsmenu/functions/fnc_onListBoxSettingsChanged.sqf
	addons/optionsmenu/functions/fnc_onListBoxShowSelectionChanged.sqf
	addons/optionsmenu/functions/fnc_onSettingsMenuOpen.sqf
	addons/optionsmenu/functions/fnc_onSliderPosChanged.sqf
	addons/optionsmenu/functions/fnc_resetSettings.sqf
	addons/optionsmenu/functions/fnc_settingsMenuUpdateKeyView.sqf
	addons/optionsmenu/functions/fnc_settingsMenuUpdateList.sqf
	addons/optionsmenu/functions/fnc_updateSetting.sqf
	addons/optionsmenu/gui/settingsMenu.hpp
2015-03-15 00:46:14 +01:00

35 lines
923 B
Plaintext

/*
* Author: Glowbal
* Called when the listbox selection is changed for an options (eg: chaning a setting from false to true)
*
* Arguments:
* None
*
* Return Value:
* None
*
* Example:
* [] call ACE_optionsmenu_fnc_onListBoxSettingsChanged
*
* Public: No
*/
#include "script_component.hpp"
private ["_settingIndex", "_rightDropDownIndex"];
_settingIndex = lbCurSel 200; //Index of left list
_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);
};
};