On Mon, 16 Feb 2026 10:43:50 GMT, Prasanta Sadhukhan <[email protected]> 
wrote:

> The FocusTraversalPolicy of a JOptionPane (JDialog) "reports" via 
> `FocusTraversalPolicy.getInitialComponent`/`FocusTraversalPolicy.getFirstComponnent`
>  that the focusable component passed to a JOptionPane, should get the initial 
> focus. This however doesn't always happen, as the text field's FocusListener 
> methods focusGained and focusLost are not invoked.
> Fix is made to honor the first focusable component of custom component (if 
> present) and set the focus accordingly..
> This will cause the component's focusGained/focusLost method to get called.
> CI testing is ok..

Couldn't find anything in the wild

-------------

PR Comment: https://git.openjdk.org/jdk/pull/29738#issuecomment-4131452583

Reply via email to