Relates :
|
|
Relates :
|
|
Relates :
|
|
Relates :
|
|
Relates :
|
|
Relates :
|
|
Relates :
|
JDK-8033699 has changed the behavior of focus traversal of radio button group by Tab key. Yet there are cases where the focus traversal doesn't work in Java 8 as expected and even where the focus gets stuck in the radio button group. In the latter case, navigation of components is broken, it's hard to move focus to another component. The attached RadioButtonGroupFocusTest.java demonstrates the case where focus gets stuck inside the radio button group. When the app starts, the selected radio button ‘A’ has the focus. Press Tab — the focus moves to ‘C’. Now the focus is stuck: the focus does not move when you press Tab or Shift-Tab. In the sample app, the buttons are added to the panel in the following order: ‘A’, ‘B’, ‘C’, ‘D’. Yet they're added to the ButtonGroup in a different order: ‘D’, ‘C’, ‘A’, ‘B’. If you add the radio buttons to the group in the same order, the focus doesn't get stuck in the radio button group.
|