Is it possible to force the JOptionPane on top of all other windows?

I'm trying to get user input with JOptionPane but can't seem to find a way to keep the pane on top of all other windows (non java windows). It's very hard to find the pane if I click somewhere else before input the value. Is there anyway to keep it on top of everything until it's value has been entered?

[315 byte] By [SuperBlueFoxa] at [2007-10-2 16:12:21]
# 1

The way to do it would probably be to use JOptionPane's createDialog method directly, and then put a listener on that dialog so that every time it loses focus, it steals it back again.

It can't be done natively because it would be extremely bad UI design to have a dialog steal focus from other windows.

trejkaza at 2007-7-13 16:58:39 > top of Java-index,Desktop,Core GUI APIs...