RFR: 8155030: The Menu Mnemonics are always displayed for GTK LAF [v6]

Abhishek Kumar abhiscxk at openjdk.org
Tue Jun 18 12:57:20 UTC 2024


On Sat, 15 Jun 2024 00:23:07 GMT, Alisen Chung <achung at openjdk.org> wrote:

>> src/java.desktop/share/classes/javax/swing/plaf/synth/SynthGraphicsUtils.java line 785:
>> 
>>> 783:             }
>>> 784: 
>>> 785:             if (c instanceof Container) {
>> 
>> JComponent extends Container ..  so this will traverse everything in the Swing UI.
>> Is there any pattern elsewhere in Swing you can use to short-circuit this ?
>
> since this method should be recursing through all of a component's subcomponents, shouldn't there not even be an if check here?

> JComponent extends Container .. so this will traverse everything in the Swing UI.
Is there any pattern elsewhere in Swing you can use to short-circuit this ?

I am unable to recall any pattern as such.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/18992#discussion_r1644413797


More information about the client-libs-dev mailing list