-
Bug
-
Resolution: Duplicate
-
P3
-
None
-
1.4.0
-
None
-
x86
-
windows_nt
Depending on who has the focus, mnemonics are working incorrectly when a JMenu has a JMenuItem with the same mnemonic. Load the attached test program and try the steps below exactly (ie. do not change the focus to the text area when the program first loads).
First, type 'ALT-t ALT-r'
Notice that the word "four" appears in the text area to show that three->four was selected.
Now type 'ALT-i'
Notice that the word "six" appears in the text area to show that five->six was selected. This is incorrect behaviour. Menu five should have become selected but not menu item six.
Now type 'ALT-i'
Nothing happens. Something weird has happened to the focus.
Now give the focus to the text area by clicking on it.
Type 'ALT-t ALT-r'.
"Four" appears as before.
Now Type 'ALT-i'
Menu five is selected.
Type 'ALT-i' again.
Item five->six gets executed and "six" is printed.
Type 'ALT-i' again.
Item five->six gets executed AGAIN and "six" is printed. This is odd because we only typed it once and menu five should have become selected, not item six.
Type 'ALT-i' again.
Nothing happens. Something weird has happened to the focus again.
First, type 'ALT-t ALT-r'
Notice that the word "four" appears in the text area to show that three->four was selected.
Now type 'ALT-i'
Notice that the word "six" appears in the text area to show that five->six was selected. This is incorrect behaviour. Menu five should have become selected but not menu item six.
Now type 'ALT-i'
Nothing happens. Something weird has happened to the focus.
Now give the focus to the text area by clicking on it.
Type 'ALT-t ALT-r'.
"Four" appears as before.
Now Type 'ALT-i'
Menu five is selected.
Type 'ALT-i' again.
Item five->six gets executed and "six" is printed.
Type 'ALT-i' again.
Item five->six gets executed AGAIN and "six" is printed. This is odd because we only typed it once and menu five should have become selected, not item six.
Type 'ALT-i' again.
Nothing happens. Something weird has happened to the focus again.
- duplicates
-
JDK-4415507 problems with focus traversal in general
-
- Resolved
-