This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 23588 - Setup Wizard - Module Installation panel : it isn't accessible by keyboard
Summary: Setup Wizard - Module Installation panel : it isn't accessible by keyboard
Status: CLOSED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Dialogs&Wizards (show other bugs)
Version: 3.x
Hardware: Sun Solaris
: P3 blocker (vote)
Assignee: mslama
URL:
Keywords: A11Y
Depends on:
Blocks:
 
Reported: 2002-05-16 10:26 UTC by Marian Mirilovic
Modified: 2008-12-23 10:36 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marian Mirilovic 2002-05-16 10:26:16 UTC
[orion](020510-rc2), [jdk1.4](fcs)

Solaris 5.8 && Solaris 5.9

Steps to reproduce:
- run IDE in MDI
- press Alt-T | W
-> Setup Wizard arise
- press Enter (go to Module Inspallation panel)
-> try to traverse by keyboard (press Tab) in the
list of modules and categories -> it's impossible!

You cannot focus nothing by keyboard until you
click mouse inside Setup window.
Comment 1 mslama 2002-05-20 11:07:28 UTC
Yes confirmed. Not specific to Solaris. I saw it on Linux RH 7.1, KDE
2.1.1 too.
Comment 2 mslama 2002-06-05 16:09:16 UTC
Evaluation: It is nasty bug. On JDK 1.4.0 we use
Container.transferFocusDownCycle() to focus component in dialog. It
calls  FocusTraversalPolicy.getDefaultComponent() and then
requestFocus() is called on this default component. Unfortunately when
 ModuleSelectionPanel is displayed for the first time
FocusTraversalPolicy returns javax.swing.JScrollPane$ScrollBar. When
you switch back and forward it then returns always
org.openide.explorer.view.TreeTable which is correct in our case.
(Actually javax.swing.LayoutFocusTraversalPolicy is used in our
container NbDialog and getDefaultComponent() is translated to
getFirstComponent().) I have no idea why it happens. All components
are already in AWT hierarchy (addNotify()) was called). Component
should be sorted from top left line by line to bottom right.

Solution would be to overwrite default
FocusTraversalPolicy.getDefaultComponent() for SetupWizard. However it
is possible only for JDK 1.4.0 and newer, not supported in JDK 1.3.1
and older. It results in ugly code.
Comment 3 mslama 2002-06-06 11:59:49 UTC
I found that FOCUS_GAINED event is received for scrollbar component
which is not visible already. Not sure if that can cause problem.
Workaround is to requestFocus() on any visible component in the same
parent => wizard stays accessible using keyboard.
Comment 4 mslama 2002-06-07 16:28:17 UTC
When second panel ModuleSelectionPanel is displayed for the first time
(regardless if user presses Enter or click on Next in previous panel)
scrollbar is focused. This scrollbar is not visible when it receives
focus (when my listener receives FOCUS_GAINED event for this
component). I do not know exactly why but from that moment all key
events has no effect. (User can click by mouse anywhere to transfer
focus to any other components and it starts to work fine. If you
switch back to previous panel using mouse and forward to
ModuleSelectionPanel it works fine too.) Only programmatical
workaround I found is to check focus events when SetupWizard is
displayed and if FOCUS_GAINED event is received for non visible
component it tries to request focus for another visible component of
the same parent. It solves this problem because there is visible
TreeTable. This should not break anything. If no visible component is
found in the same parent nothing happens.
Comment 5 mslama 2002-06-07 17:28:14 UTC
Fixed in main trunk as described above: Try to transfer focus to any
visible component of the same parent when invisible component is focused.

Modified:
core/src/org/netbeans/core/ui/SetupWizard.java r.1.10
Comment 6 Marian Mirilovic 2002-10-09 10:49:15 UTC
verified in [nb_dev](20021009)
Comment 7 Quality Engineering 2003-07-01 16:37:30 UTC
Resolved for 3.4.x or earlier, no new info since then -> closing.