mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Fix mappos not saving
This commit is contained in:
@ -28,7 +28,7 @@ if (_newDisplayShowMode == -1) then {
|
|||||||
if ((_newDisplayShowMode == DISPLAY_MODE_DISPLAY) && {!([DISPLAY_MODE_DISPLAY] call FUNC(canShow))}) then {_newDisplayShowMode = DISPLAY_MODE_HIDDEN};
|
if ((_newDisplayShowMode == DISPLAY_MODE_DISPLAY) && {!([DISPLAY_MODE_DISPLAY] call FUNC(canShow))}) then {_newDisplayShowMode = DISPLAY_MODE_HIDDEN};
|
||||||
if ((_newDisplayShowMode == DISPLAY_MODE_DIALOG) && {!([DISPLAY_MODE_DIALOG] call FUNC(canShow))}) then {_newDisplayShowMode = DISPLAY_MODE_HIDDEN};
|
if ((_newDisplayShowMode == DISPLAY_MODE_DIALOG) && {!([DISPLAY_MODE_DIALOG] call FUNC(canShow))}) then {_newDisplayShowMode = DISPLAY_MODE_HIDDEN};
|
||||||
|
|
||||||
GVAR(currentShowMode) = _newDisplayShowMode;
|
|
||||||
|
|
||||||
//On first-startup
|
//On first-startup
|
||||||
if (GVAR(currentApplicationPage) == APP_MODE_NULL) then {
|
if (GVAR(currentApplicationPage) == APP_MODE_NULL) then {
|
||||||
@ -36,7 +36,7 @@ if (GVAR(currentApplicationPage) == APP_MODE_NULL) then {
|
|||||||
GVAR(mapPosition) = getPos ace_player;
|
GVAR(mapPosition) = getPos ace_player;
|
||||||
};
|
};
|
||||||
|
|
||||||
if (GVAR(currentShowMode) in [DISPLAY_MODE_CLOSED, DISPLAY_MODE_HIDDEN]) then {
|
if (_newDisplayShowMode in [DISPLAY_MODE_CLOSED, DISPLAY_MODE_HIDDEN]) then {
|
||||||
|
|
||||||
//If Dialog is open, back it up before closing:
|
//If Dialog is open, back it up before closing:
|
||||||
if (dialog && {!isNull (uiNamespace getVariable [QGVAR(DialogDisplay), displayNull])}) then {
|
if (dialog && {!isNull (uiNamespace getVariable [QGVAR(DialogDisplay), displayNull])}) then {
|
||||||
@ -47,7 +47,7 @@ if (GVAR(currentShowMode) in [DISPLAY_MODE_CLOSED, DISPLAY_MODE_HIDDEN]) then {
|
|||||||
//Close the display:
|
//Close the display:
|
||||||
(QGVAR(TheRscTitleDisplay) call BIS_fnc_rscLayer) cutText ["", "PLAIN"];
|
(QGVAR(TheRscTitleDisplay) call BIS_fnc_rscLayer) cutText ["", "PLAIN"];
|
||||||
} else {
|
} else {
|
||||||
if (GVAR(currentShowMode) == DISPLAY_MODE_DISPLAY) then {
|
if (_newDisplayShowMode == DISPLAY_MODE_DISPLAY) then {
|
||||||
//If Dialog is open, back it up before closing:
|
//If Dialog is open, back it up before closing:
|
||||||
if (dialog && {!isNull (uiNamespace getVariable [QGVAR(DialogDisplay), displayNull])}) then {
|
if (dialog && {!isNull (uiNamespace getVariable [QGVAR(DialogDisplay), displayNull])}) then {
|
||||||
[-1] call FUNC(saveCurrentAndSetNewMode);
|
[-1] call FUNC(saveCurrentAndSetNewMode);
|
||||||
@ -55,7 +55,7 @@ if (GVAR(currentShowMode) in [DISPLAY_MODE_CLOSED, DISPLAY_MODE_HIDDEN]) then {
|
|||||||
};
|
};
|
||||||
//Open the display:
|
//Open the display:
|
||||||
(QGVAR(TheRscTitleDisplay) call BIS_fnc_rscLayer) cutRsc [QGVAR(TheRscTitleDisplay), "PLAIN", 0, true];
|
(QGVAR(TheRscTitleDisplay) call BIS_fnc_rscLayer) cutRsc [QGVAR(TheRscTitleDisplay), "PLAIN", 0, true];
|
||||||
} else {
|
} else { //DISPLAY_MODE_DIALOG
|
||||||
//Close the display:
|
//Close the display:
|
||||||
(QGVAR(TheRscTitleDisplay) call BIS_fnc_rscLayer) cutText ["", "PLAIN"];
|
(QGVAR(TheRscTitleDisplay) call BIS_fnc_rscLayer) cutText ["", "PLAIN"];
|
||||||
//Open the dialog:
|
//Open the dialog:
|
||||||
@ -63,6 +63,7 @@ if (GVAR(currentShowMode) in [DISPLAY_MODE_CLOSED, DISPLAY_MODE_HIDDEN]) then {
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
GVAR(currentShowMode) = _newDisplayShowMode;
|
||||||
[] call FUNC(showApplicationPage);
|
[] call FUNC(showApplicationPage);
|
||||||
|
|
||||||
if ((_oldShowMode == DISPLAY_MODE_CLOSED) && {GVAR(currentShowMode) != DISPLAY_MODE_CLOSED}) then {
|
if ((_oldShowMode == DISPLAY_MODE_CLOSED) && {GVAR(currentShowMode) != DISPLAY_MODE_CLOSED}) then {
|
||||||
|
@ -106,7 +106,7 @@ if (GVAR(currentApplicationPage) == APP_MODE_MARK) then {
|
|||||||
//Mode: Setting
|
//Mode: Setting
|
||||||
(_display displayCtrl IDC_MODESETTINGS) ctrlShow (GVAR(currentApplicationPage) == APP_MODE_SETUP);
|
(_display displayCtrl IDC_MODESETTINGS) ctrlShow (GVAR(currentApplicationPage) == APP_MODE_SETUP);
|
||||||
|
|
||||||
//Button's pushed:
|
//Buttons pushed:
|
||||||
if (GVAR(currentApplicationPage) == APP_MODE_INFODISPLAY) then {
|
if (GVAR(currentApplicationPage) == APP_MODE_INFODISPLAY) then {
|
||||||
(_display displayCtrl IDC_BUTTONBG0) ctrlSetText QUOTE(PATHTOF(images\button_pushedDown.paa));
|
(_display displayCtrl IDC_BUTTONBG0) ctrlSetText QUOTE(PATHTOF(images\button_pushedDown.paa));
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user