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 150216 - Drop Down List with drivers lose focus after chossing some item
Summary: Drop Down List with drivers lose focus after chossing some item
Status: VERIFIED FIXED
Alias: None
Product: db
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Rob Englander
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-15 13:06 UTC by Roman Mostyka
Modified: 2009-02-19 20:37 UTC (History)
1 user (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 Roman Mostyka 2008-10-15 13:06:14 UTC
1. Rightclick "Databases" node and choose "New Connection...".
2. Press Tab key until drop down list with available drivers will have focus.
3. Press Down key on keyboard to choose next driver.

Result: Next driver is chosen, but Drop Down List lose focus and next Text Filed get it and it isn't possible to easily
choose driver following by next or further by keyboard. Seems like usability issue.
Comment 1 David Vancouvering 2008-10-28 20:33:43 UTC
This is a P3 - workaround is easy, use the mouse instead.
Comment 2 Rob Englander 2008-10-29 14:59:15 UTC
Can you clarify?  What I'm seeing is that as you use the up and down keys there is a perceived loss
of focus when you move from a named driver to "New Driver...", or from "New Driver..." to a named driver.
The remainder of the keyboard navigation here looks right to me.

Let me know if this is what you mean, or if not please clarify.  Thanks.
Comment 3 Rob Englander 2008-10-29 15:01:57 UTC
Nevermind.  I see what you're describing.  Hitting enter does not select "New Driver...".

Have you also seen the focus "gap" that I described?
Comment 4 Rob Englander 2008-10-29 16:20:15 UTC
I have the fix.

The focus gap I was describing appears to be that the separator (the separator between the named drivers
and "New Driver...") isn't rendering.  I'm running on a Mac.  Is this separator supposed to render?
Comment 5 Roman Mostyka 2008-10-29 18:07:07 UTC
I didn't try on Mac, but for me this issue reproducible not only by attempt to move from "New Driver..." to named or
vise versa, it is reproducible when I try with Up and Down keys choose any driver in drop down list.
Comment 6 Rob Englander 2008-10-29 18:10:39 UTC
Wow.  That IS bad.  The bug I found looks like it could introduce a timing error which may be
responsible for the behavior being different on various systems.  What platform have you seen
the worst of this?  I can try to validate my fix on another platform. 
Comment 7 Rob Englander 2008-10-29 18:22:48 UTC
I'm pretty sure I have the navigation fixed.  The bug is not in the connection dialog,
it's actually in DataComboBoxSupport.  

I'd like to address the separator between the named drivers and "New Driver...".  There are
multiple bugs there.  The first one is that it doesn't render, at least not on all platforms.
The second problem is that when using keyboard navigation it doesn't move the selection
to the next, or previous, item in the list as appropriate.  This results in the combo box appearing
to have lost focus when that is not the case.

I'm proposing to simply eliminate the separator.  It will simplify things here.  However, if we
want to retain it, I'd suggest opening a separate issue.  So on the Mac it doesn't currently render.
Does it render on Windows?  Linux?  Solaris?
Comment 8 David Vancouvering 2008-10-29 18:40:45 UTC
Simplifying things by removing the separator makes sense to me, rather than spending all our time trying to fix this on
the various platforms.
Comment 9 Rob Englander 2008-10-29 18:46:20 UTC
Will do.  

BTW I'm not sure it renders on any platform.  I'd like to know the answer to that
anyway.
Comment 10 Rob Englander 2008-10-29 21:53:31 UTC
11547f9bf607
Comment 11 Quality Engineering 2008-10-30 04:57:01 UTC
Integrated into 'main-golden', will be available in build *200810300201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/11547f9bf607
User: Rob Englander <mindstream@netbeans.org>
Log: #150216 Corrected the keyboard navigation for the drivers combobox in the New Connection dialog.  Also removed the separator, which did not work and caused the user to think the component had lost focus.
Comment 12 Roman Mostyka 2008-10-30 19:21:58 UTC
Verified with build 081030.
Comment 13 pgebauer 2008-11-10 15:07:00 UTC
Since this issue is P3 priority, in accord with rules "How to include issues into patch"
(http://wiki.netbeans.org/NetBeansPatches) it must include an explanation as to why its backport is necessary and how
safe it is.

Could you please provide such explanation?
Comment 14 Roman Mostyka 2008-11-10 17:51:39 UTC
This issue is important to have since it is A11Y related issue and if customer use only keyboard, it can be very, very
annoying to add new connection.
And this issue was P2 in the beginning and therefore I added status whiteboard.
But if anybody think that it is rare case, then I can remove status whiteboard.
Rob, could you tell how the fix is safe?
Comment 15 Rob Englander 2008-11-10 18:07:51 UTC
The fix is highly isolated.  It is only in the code that handles the events that are raised by that combobox.  It is
very safe as the code now follows standard event handling instead of having multiple handlers as it had before.
Comment 16 rbalada 2008-11-18 13:47:41 UTC
I've transplanted the changeset http://hg.netbeans.org/main/rev/11547f9bf607 into release65_fixes repository as
http://hg.netbeans.org/release65_fixes/rev/ed7fb0ebcd05