RFR: 8274854: Mnemonics for menu containing numeric text not working

Ajit Ghaisas aghaisas at openjdk.java.net
Fri Oct 29 11:27:14 UTC 2021


On Wed, 20 Oct 2021 16:54:35 GMT, Michael Strauß <mstrauss at openjdk.org> wrote:

> This PR fixes an issue with mnemonic parsing by removing the restriction that a mnemonic symbol must be a letter. Now, it can be any character except whitespace.

modules/javafx.controls/src/main/java/com/sun/javafx/scene/control/behavior/TextBinding.java line 238:

> 236:         }
> 237: 
> 238:         return !isExtendedMnemonic(s, position);

I am not sure why do we need to check for isExtendedMnemonic() inside isSimpleMnemonic() implementation.
These two methods should be separate and it is up to the callers to check and take appropriate action.

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

PR: https://git.openjdk.java.net/jfx/pull/647


More information about the openjfx-dev mailing list