<Swing Dev> [14] RFR JDK-8223788 - [macos] JSpinner buttons in JColorChooser dialog may capture focus using TAB Key

Tejpal Rebari tejpal.rebari at oracle.com
Fri Jan 10 09:32:05 UTC 2020


Hi Sergey,
I had removed the colorchooser and created a frame and added two spinner to it.
Then noticed that the issue is reproducible only when the ContainerOrderFocusTraversalPolicy is set.
When ContainerOrderFocusTraversalPolicy is set, in JSpinner there are four components which captures focus 
		1)JSpinner 
		2)JSpinner$NumberEditor 
		3)JFormattedTextField 
		4)AquaSpinnerUI$SpinPainter

In JColorChooser, SlidingSpinner is used which sets focusable property to false for 1)JSpinner and 2)JSpinner$NumberEditor

So in the test I used ContainerOrderFocusTraversalPolicy and set the focusable property false for 1)JSpinner and 2)JSpinner$NumberEditor and then check that the spinpainter is capturing focus or not.

Here is the updated webrev : http://cr.openjdk.java.net/~trebari/swing/8223788/webrev2/ <http://cr.openjdk.java.net/~trebari/swing/8223788/webrev2/>

Regards
Tejpal


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/swing-dev/attachments/20200110/aba0a977/attachment.htm>


More information about the swing-dev mailing list