<Swing Dev> [11] JDK-8194873: right ALT key hotkeys no longer work in Swing components

Pankaj Bansal pankaj.b.bansal at oracle.com
Mon Mar 26 12:06:46 UTC 2018


Hi All,

 

Please review the test only fix for JDK 11.

 

Bug:

https://bugs.openjdk.java.net/browse/JDK-8194873

 

webrev:

http://cr.openjdk.java.net/~pbansal/8194873/webrev.00/

 

 

Issue:

The right ALT key is not working as mnemonic for some Swing components like JMenu or JOptionsPane. The left ALT key works fine.

 

Fix:

This issue was introduced when a check for VK_RMENU was added in GetJavaModifiers function in awt_Component.cpp. Windows gives true for both VK_MENU and VK_RMENU when right ALT (ALT_GRAPH ) key is pressed. Due to which extra bits are set on modifiers. So the mnemonic bindings should be updated to work with both ALT and (ALT+ALT_GRAPH) modifiers. Changes have been made in mnemonic bindings.  

 

Regards,

Pankaj Bansal
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/swing-dev/attachments/20180326/67350f4c/attachment.html>


More information about the swing-dev mailing list