Opened 13 years ago

Closed 12 years ago

#825 closed enhancement (fixed)

Make Enter/Esc work when a dialog is open

Reported by: Kieran P Owned by:
Priority: Nice to Have Milestone: Alpha 11
Component: UI & Simulation Keywords:
Cc: Patch:

Description

Should be able to press enter when a dialog is opened.

e.g. if I select a unit, then hit "Delete" on the keyboard, I should be able to press enter to confirm it.

Likewise, if it doesn't work already, 'Escape' on the keyboard should trigger the 'cancel' action.

Change History (6)

comment:1 by historic_bruno, 13 years ago

If would be nice if the GUI engine had proper keyboard support (something like what #698 outlines)

comment:2 by Kieran P, 13 years ago

Milestone: Alpha 6Alpha 7

comment:3 by Kieran P, 13 years ago

Priority: Should HaveNice to Have

comment:4 by Kieran P, 13 years ago

Milestone: Alpha 7Backlog

comment:5 by Matt Doerksen, 12 years ago

I spent some time looking into this and based on the current implementation this isn't going to work (without some major hacks anyways). There just isn't any way to hook into the keyboard for escape/enter without it being handled by the main input function. If we get to that level, we'd have to make some hacks to check if something is open and accept/close it based on the key, which will become very ugly very fast.

TLDR; not possible with the current messagebox implementation.

comment:6 by leper, 12 years ago

Milestone: BacklogAlpha 11
Resolution: fixed
Status: newclosed

This was implemented in r12503/#1319.

Note: See TracTickets for help on using tickets.