You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The exit prompt modal that appears when user selects File -> Exit does not exit MegaMekLab.
The exit prompt modal that appears when a user clicks on the [X] button in the top-right corner of the frame does exit.
Expectation:
Both methods instantiate the same modal with the same code and functionality.
Answering "Yes" or "No" in the Modal either saves, or does not, followed by exiting the program.
Actual:
They don't function the same.
Neither option in the first modal exits.
This affects both custom and cache-only units.
This happens whether the user selects "Yes" or "No", although the Save functionality does work in both modals.
Cause is: menu entry's frame is the menu bar, while the exit button's frame is the main UI frame. Need to instantiate the Exit menu entry's exit call with the main UI frame somehow.
Actual cause: menu item "Exit" never actually calls System.exit(); it just returns a boolean that is dropped immediately and does nothing.
Proposed fix: wrap the existing lambda in a conditional exit function that will exit if that is appropriate.
Sleet01
added a commit
to Sleet01/megameklab
that referenced
this issue
Jul 30, 2023
Environment
Description
The exit prompt modal that appears when user selects
File -> Exit
does not exit MegaMekLab.The exit prompt modal that appears when a user clicks on the [X] button in the top-right corner of the frame does exit.
Expectation:
Actual:
This affects both custom and cache-only units.
This happens whether the user selects "Yes" or "No", although the Save functionality does work in both modals.
Files
megamek.log
CLI debug logging for MML showing
File -> Exit
modal saving but not exiting, then[X]
modal saving and exiting.20230729_1605_mml_exit_issue.log
The text was updated successfully, but these errors were encountered: