How to make a JDialog not always on top of parent
As stated in this Q&A: setModal issue with 2 Jdialogs within a Jframe:
This behaviour depends on how native windowing system handles focused and active windows. Having said this if you call for instance toFront() it will attempt to place the window at the top of the stack BUT some platforms do not allow windows which own other windows to appear on top of its children. The same happens when you call toBack() method. See the javadocs for more details.
For instance on Windows 7 parent dialog becomes focused but its children still showing (not focused) at the top. As mentioned above it's up to the windowing system decide how to handle this matter.