A Flex Alternative to 'Are You Sure' Dialogs
Join the DZone community and get the full member experience.Join For Free
One of my pet hates in interaction design is the use of confirmation dialogs before the user attempts to do anything of worth. More often than not, with a bit of thought most user actions could be recoverable and rather than stopping the proceedings with idiocy the user could simply press 'undo' and return to their previous state.
One of my favourite articles bemoaning the use of modal dialogs is this one by Jeff Atwood.
However, sometimes a user's action isn't undoable. For instance, detonating an explosive charge ain't easy to undo. In scenarios like this, modal confirmation dialogs still aren't a real solution. Users don't read the text in dialog boxes and simply pressing 'ok' becomes habitual.
What's needed in these situations is a button that requires a definite and decisive user action and maybe my PressAndHoldButton does the trick. This requires the user to keep the button held down for some period of time before firing an event.
The demo has three buttons - before any of those actions are performed, the user has to keep the relevant button depressed for five seconds.
The demo application is available here and the source code here.
Published at DZone with permission of Simon Gladman, DZone MVB. See the original article here.
Opinions expressed by DZone contributors are their own.