hi Greg,
if you want to stick with focusLost - the only solution that comes to my mind is to check in this listener method whether "cancel" has been clicked. Though I think that won't work as the focus is lost before the button is clicked.
If you don't have to stick with focusLost, use the document events of the text fields to check the input, or use JFormattedField, or use a generated Parser (from ANTLR, e.g.). At first glance these solutions might mean more overhead than listening to focusLost but I don't think that this is noticeable. the advantage of controlling the input as it is typed in, is that you can give the user an immediate feedback - in fact this has the consequence that the interface is more responsive to user input and thus seems "faster". of course the typing performance must not suffer from it.
I am using an ANTLR generated parser for controlling a text field. While the input is invalid, the entered text is displayed in red, as soon as the input is valid the text is displayed in black. this works very fine.
regards,
Chantal