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.
[dev dec 03, JDK 1.4.1, Linux, MDI] I am trying recent (0.8.11, current Dev Alpha Daily) versions of the available tasklist modules. There does not seem to be easy keyboard access to the suggestions. I opened Suggestions View Source Tasks with TopManager.java open in the editor. Both tabs showed one suggestion. But how to navigate to it from the keyboard? View | Editor Scan List opens or selects the component. But it does not give it KB focus. Fine, try Ctrl-4 to open the Output Window, then Alt-Left (e.g.) to switch to the Source Tasks tab. Down Arrow does nothing. After pressing Tab, then the (invisible) KB focus switches into the table and you can navigate through the suggestions. Recommendations: 1. View | Something menu item should not only open and front the Something tab, it should give it focus (select it). This would be consistent with the behavior of other View menu items. 2. Selecting any tasklist suggestions tab should immediately place KB focus in the table, not requiring a separate TAB press. Probably it should also select the first item in the table if there was no selection before. 3. If there is some way to provide KB focus for the table headers (not as the default focus entry point of course!), to enable KB-driven changing of sort mode and columns, that would be nice. I was unable to find any such technique, using combinations of TAB and Control-TAB (Control-TAB is generally needed to exit focus out of a complex component such as a table, tree, or text area). 4. Consider providing mnemonics for the View menu items, especially as they have no keyboard shortcuts defined. (Thanks for remembering to put them in Actions/View, though, as this makes it possible for the user to add keyboard shortcuts.)
Potential Sec 508 issues for handicapped users, as well as general efficiency of UI and ease of use.
Thanks for this very specific report. I added a (TopComponent)requestFocus() call at the end of the code which is called when a tasklist window is opened, but it does not seem to get focus to the component. Adding keyboard mnemonics to the menus is a good idea too.
Try checking core sources (e.g. OutputWindowAction) for hints.
I did and requestFocus() is it. But there might be something else going on; I'll make sure that this is happening on the AWT thread, etc.
I saw a code snippet on nbdev which implemented requestFocus for a top component by calling requestFocus on the treetable itself - so I'm doing that, but still no success. However, it might be related to issue 31456.
Tim might know what to do here, I have no idea...
BTW contrib/focusmodule may be helpful for debugging. Tim says the tree table view is actually a scroll pane so giving it focus is pretty much useless.
Ah. Then perhaps searching for a JTable inside the treetableview reference and requestin focus on that might solve the problem.
Tor, try moving the call to requestFocus() into addNotify() for your TopComponent - it will probably work. The tree view subclasses JScrollPane (for reasons lost in the depths of antiquity) but will delegate requestFocus to the contained component). AddNotify() is more likely to put your call at the end of the chain of whatever random things the window system is doing with focus. Long term, all such calls are evil - the first steps in solving focus issues are: 1. Wait until we don't have to support 1.3 (different focus model) 2. Delete every single focus related call in core/openide and all standard modules 3. See where the problems are once all of the strange focus-related hacks are killed 4. Fix them via 1.4's infrastructure
I changed the code from treeTableView.requestFocus() to treeTableView.getTable().requestFocus() and now it works properly. The "addNotify" trick won't quite do because there are actions to "show" the tasklist windows, and if they've already been added (but are not currently in front), addNotify won't be called, but requestFocus() will, so I need requestFocus() to work. P.S. getTable() isn't a method in TreeTableView. I've already subclassed TreeTableView to change a couple of the table properties (intercell spacing if I remember correctly), so I just added this accessor to let me do the above focus request as well.
I believe all of this is fixed except the tab-once-to-reach-table issue, so downgrading the issue to P4.
I cannot reproduce remaining tab-once-to-reach-table issue. Up/Down navigation works immediately over table items. What have you mean by that?
Use Shift-Tab in the first cell to change visible columns --Tim
Fixed for TODOs: open, context selection, refresh and filter actions place focus to the table.
should be fixed in recent builds