Preventing a Window from Gaining the Focus
If Window.setFocusableWindowState(false) is called on a window,
neither the window nor any of its children components can gain the
focus. However, components like buttons can still invoke actions.
On some platforms, if the non-focusable window is the only
window visible in the application, the non-focusable window will gain
the focus. However, none of the children components will gain the
focus.
frame.setFocusableWindowState(false);
Post a comment