Input dialog is often used to collect a single value and do something with it.
It would be cool if we had a way to let user confirm/submit the primary action of the dialog by hitting ENTER and to having to resort to grabbing a mouse and licking the OK button.
.withActions(
new DialogAction(DialogAction.Type.YES, Action.Status.PRIMARY)
.withHandler(e -> doSomething()),
new DialogAction(DialogAction.Type.NO)
)
Hi Chris, thanks, yes I’ve seen that but I believe this type of .whitActions() is available only for OptionDialogBuilder, not for InputDialogBuilder. Happy to be proven wrong (ideally by demoing an example for input dialog
Also in input dialog, I need to collect value(s) from input(s) within close listener as demonstrated in my mock example above after dialog is closed by that action.
@pinyazhin Dear Roman, could you please re-write the code for Jmix2.x? I am lost and cant get it working.
Especially the shortcuts ant the Actions are a nightmare.
Thank you very much in advance.
Regards
Tomas