2015-03-06 17:15:32 +00:00
|
|
|
/*
|
|
|
|
* Author: Glowbal
|
2015-03-14 18:10:25 +00:00
|
|
|
* Changes which tab is open (options or colors)
|
2015-03-06 17:15:32 +00:00
|
|
|
*
|
|
|
|
* Arguments:
|
2015-03-14 18:10:25 +00:00
|
|
|
* The tab to open (defined in script_component) <NUMBER>
|
2015-03-06 17:15:32 +00:00
|
|
|
*
|
|
|
|
* Return Value:
|
2015-03-14 18:10:25 +00:00
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Example:
|
|
|
|
* [MENU_TAB_COLORS] call ACE_optionsmenu_fnc_onListBoxShowSelectionChanged
|
2015-03-06 17:15:32 +00:00
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
|
|
|
|
2015-01-21 11:43:58 +00:00
|
|
|
#include "script_component.hpp"
|
|
|
|
|
2015-01-21 22:00:54 +00:00
|
|
|
private ["_settingsMenu", "_localizedHeader"];
|
2015-01-21 11:43:58 +00:00
|
|
|
|
|
|
|
PARAMS_1(_openTab);
|
|
|
|
GVAR(optionMenu_openTab) = _openTab;
|
|
|
|
|
|
|
|
disableSerialization;
|
|
|
|
_settingsMenu = uiNamespace getVariable 'ACE_settingsMenu';
|
|
|
|
|
|
|
|
switch (GVAR(optionMenu_openTab)) do {
|
|
|
|
case (MENU_TAB_OPTIONS): {
|
2015-01-21 22:00:54 +00:00
|
|
|
_localizedHeader = format ["%1: %2", (localize "STR_ACE_OptionsMenu_OpenConfigMenu"), (localize "STR_ACE_OptionsMenu_TabOptions")];
|
2015-01-21 11:43:58 +00:00
|
|
|
ctrlSetText [13, _localizedHeader];
|
|
|
|
lbClear 400;
|
|
|
|
|
|
|
|
(_settingsMenu displayCtrl 301) ctrlShow true;
|
|
|
|
|
|
|
|
(_settingsMenu displayCtrl 400) ctrlShow true;
|
|
|
|
(_settingsMenu displayCtrl 410) ctrlShow false;
|
|
|
|
(_settingsMenu displayCtrl 411) ctrlShow false;
|
|
|
|
(_settingsMenu displayCtrl 412) ctrlShow false;
|
|
|
|
(_settingsMenu displayCtrl 413) ctrlShow false;
|
|
|
|
};
|
|
|
|
case (MENU_TAB_COLORS): {
|
2015-01-21 22:00:54 +00:00
|
|
|
_localizedHeader = format ["%1: %2", (localize "STR_ACE_OptionsMenu_OpenConfigMenu"), (localize "STR_ACE_OptionsMenu_TabColors")];
|
2015-01-21 11:43:58 +00:00
|
|
|
ctrlSetText [13, _localizedHeader];
|
|
|
|
|
|
|
|
lbClear 400;
|
|
|
|
|
|
|
|
(_settingsMenu displayCtrl 301) ctrlShow false;
|
|
|
|
|
|
|
|
(_settingsMenu displayCtrl 400) ctrlShow false;
|
|
|
|
(_settingsMenu displayCtrl 410) ctrlShow true;
|
|
|
|
(_settingsMenu displayCtrl 411) ctrlShow true;
|
|
|
|
(_settingsMenu displayCtrl 412) ctrlShow true;
|
|
|
|
(_settingsMenu displayCtrl 413) ctrlShow true;
|
|
|
|
|
2015-01-21 20:23:33 +00:00
|
|
|
(_settingsMenu displayCtrl 410) sliderSetRange [0, 255];
|
|
|
|
(_settingsMenu displayCtrl 411) sliderSetRange [0, 255];
|
|
|
|
(_settingsMenu displayCtrl 412) sliderSetRange [0, 255];
|
|
|
|
(_settingsMenu displayCtrl 413) sliderSetRange [0, 255];
|
2015-01-21 11:43:58 +00:00
|
|
|
};
|
|
|
|
};
|
2015-01-21 20:23:33 +00:00
|
|
|
|
|
|
|
[true] call FUNC(settingsMenuUpdateList);
|