RFR: 8348760: RadioButton is not shown if JRadioButtonMenuItem is rendered with ImageIcon in WindowsLookAndFeel [v38]

Alexey Ivanov aivanov at openjdk.org
Tue Aug 12 12:11:30 UTC 2025


On Mon, 11 Aug 2025 16:22:15 GMT, Alexey Ivanov <aivanov at openjdk.org> wrote:

>> src/java.desktop/share/classes/com/sun/java/swing/SwingUtilities3.java line 251:
>> 
>>> 249: 
>>> 250:     public static void setAcceleratorSelectionForeground(Color acceleratorSelectionFg) {
>>> 251:         acceleratorForeground = acceleratorSelectionFg;
>> 
>> I just noticed this "oops". This should be acceleratorSelectionForeground.
>> Do we not have a test that would spot this ?
>
> Yes, you're right!
> 
> I was curious why my IDE showed `acceleratorSelectionForeground` in grey as if unused. It's used but never assigned.

> I just noticed this "oops". This should be acceleratorSelectionForeground. Do we not have a test that would spot this ?

I've submitted [JDK-8365375](https://bugs.openjdk.org/browse/JDK-8365375): _Method SU3.setAcceleratorSelectionForeground assigns to acceleratorForeground_.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/23324#discussion_r2269635271


More information about the client-libs-dev mailing list