mojira.dev
MC-301687

Dialogs close when pressing esc, even when `after_action` is set to `none`

Usually all buttons on a dialog, and the esc key, close the dialog and returns you to the last non-dialog screen, if any. In case the dialog was initially opened from the pause menu, this means you return to the pause menu.

You can override this by setting after_action to none. This will not close the dialog when pressing any of the buttons, including the one created for the exit_action. However, I expected the esc key to behave the same way as the button for exit_action, which it currently does not.

I have also attached a video to illustrate and explain this issue, explaining what the issue is and why it is an issue for custom content (enable sound):

[embedCard]

Steps to Reproduce

  1. Download [mediaInline]

  2. Install it in a world

  3. If the world is open, close and re-open it, otherwise just open it

  4. Pause the game

  5. Click “Custom Options”

  6. Click “Settings”

  7. Click “Automatic Game End”

  8. Click “Back”

  9. Click “Automatic Game End” again

  10. Press esc on your keyboard

Observed Behavior

esc closes the dialog and brings you back to the pause menu, ignoring after_action.

Expected Behavior

Both the back button and the esc button behave the same and respect the after_action argument.

MC-298457 confirms that the button of exit_action is in fact not supposed to close the dialog, and I expected esc to also follow this same logic.

Linked issues

Attachments

Comments 0

No comments.

NeunEinser

(Unassigned)

Unconfirmed

Data Packs

1.21.8, 25w35a

Retrieved