J
Jason Cavett
I am wondering if there is a nice easy way to restore a JComboBox
selection (other than the obvious).
Basically, I have placed an ActionListener on a JComboBox. However,
when the listener is fired (which happens after the new selection has
been made), I have to ask the user some questions. If they choose not
to go through with the change, I want to revert back to the previous
value. Is there a way to do this that is better than keeping around a
reference that stores the current selection at all times?
I looked for a listener that capture the change *before* it went
through, but I haven't seen anything.
Thanks,
Jason
selection (other than the obvious).
Basically, I have placed an ActionListener on a JComboBox. However,
when the listener is fired (which happens after the new selection has
been made), I have to ask the user some questions. If they choose not
to go through with the change, I want to revert back to the previous
value. Is there a way to do this that is better than keeping around a
reference that stores the current selection at all times?
I looked for a listener that capture the change *before* it went
through, but I haven't seen anything.
Thanks,
Jason