Skip to content

Commit

Permalink
add menu option for cba settings (#641)
Browse files Browse the repository at this point in the history
  • Loading branch information
commy2 authored Apr 13, 2017
1 parent 1b8c457 commit 2e9cd00
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion addons/settings/Display3DEN.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class Display3DEN {
};
class ADDON {
text = CSTRING(3den_shortcut);
action = QUOTE(findDisplay 313 call COMPILE_FILE(openSettingsMenu));
action = QUOTE(findDisplay 313 call FUNC(openSettingsMenu));
data = QUOTE(ADDON);
shortcuts[] = {INPUT_CTRL_OFFSET + INPUT_ALT_OFFSET + DIK_S};
};
Expand Down
1 change: 1 addition & 0 deletions addons/settings/XEH_PREP.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ PREP(clear);
PREP(priority);

if (hasInterface) then {
PREP(openSettingsMenu);
PREP(gui_addonChanged);
PREP(gui_sourceChanged);
PREP(gui_configure);
Expand Down
2 changes: 1 addition & 1 deletion addons/settings/XEH_preInit.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,6 @@ if (isServer) then {
[_setting, _value, _priority, "mission", _store] call FUNC(set);
}] call CBA_fnc_addEventHandler;

//[localize LSTRING(menu_button), "RscDisplayGameOptions"] call CBA_fnc_addPauseMenuOption;
[[localize LSTRING(menu_button)], QGVAR(MainMenuHelper)] call CBA_fnc_addPauseMenuOption;

ADDON = true;
File renamed without changes.
10 changes: 9 additions & 1 deletion addons/settings/gui.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ class RscDisplayGameOptions {
};

class GVAR(ButtonConfigure_base): RscButtonMenu {
onButtonClick = QUOTE(ctrlParent (_this select 0) call COMPILE_FILE(openSettingsMenu));
onButtonClick = QUOTE(ctrlParent (_this select 0) call FUNC(openSettingsMenu));
idc = IDC_BTN_CONFIGURE;
text = CSTRING(configureAddons);
x = POS_X_LOW(11.1);
Expand Down Expand Up @@ -503,3 +503,11 @@ class GVAR(presets) {
};
};
};

class RscDisplayEmpty;
class GVAR(MainMenuHelper): RscDisplayEmpty {
onLoad = QUOTE(\
(_this select 0) call FUNC(openSettingsMenu);\
(_this select 0) closeDisplay 0;\
);
};

0 comments on commit 2e9cd00

Please sign in to comment.