ACE3/addons/optionsmenu/functions/fnc_resetSettings.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

38 lines
769 B
Plaintext

/*
* Author: Glowbal
* Resets all settings to default.
*
* Arguments:
* None
*
* Return Value:
* None
*
* Example:
* [] call ACE_optionsmenu_fnc_onListBoxSettingsChanged
*
* Public: No
*/
#include "script_component.hpp"
private ["_name", "_default", "_lastSelected"];
{
_name = _x select 0;
_default = _x select 7;
[MENU_TAB_OPTIONS, _name, _default] call FUNC(updateSetting);
} forEach GVAR(clientSideOptions);
{
_name = _x select 0;
_default = _x select 7;
[MENU_TAB_COLORS, _name, _default] call FUNC(updateSetting);
} forEach GVAR(clientSideColors);
_lastSelected = lbCurSel 200;
[GVAR(optionMenu_openTab)] call FUNC(onListBoxShowSelectionChanged);
if (_lastSelected != -1) then {
lbSetCurSel [200, _lastSelected];
};