Closed Bug 387499 Opened 17 years ago Closed 17 years ago

keys (Up/Down/any character) no longer working in collapsed XUL combo boxes

Categories

(Core :: XUL, defect)

defect
Not set
major

Tracking

()

RESOLVED FIXED

People

(Reporter: jdiggs, Assigned: enndeakin)

References

Details

(Keywords: access, regression)

Attachments

(1 file)

Steps to reproduce:

1. Navigate to a combo box such as the "When Minefield Starts:" combo box in Minefield's Preference's dialog or the "Style:" combo box on the Display pane for Thunderbird's Preferences dialog.

2. With the combo box collapsed, use Up/Down Arrow to move among the choices.

Expected results:  Up/Down Arrow would allow you to navigate among items in the combo box.

Actual results: Up/Down Arrow do nothing.

This seems to have been introduced in the 5th July builds.
Component: Keyboard: Navigation → XP Toolkit/Widgets: Menus
Flags: blocking1.9?
OS: Linux → All
QA Contact: keyboard.navigation → xptoolkit.menus
Hardware: PC → All
Summary: Up/Down Arrow no longer works in collapsed XUL combo boxes → keys (Up/Down/any character) no longer working in collapsed XUL combo boxes
Severity: normal → major
Keywords: access, sec508
Assignee: nobody → enndeakin
Status: NEW → ASSIGNED
Attachment #272397 - Flags: superreview?(bzbarsky)
Attachment #272397 - Flags: review?
Attachment #272397 - Flags: review? → review?(neil)
Flags: in-testsuite?
Comment on attachment 272397 [details] [diff] [review]
handle keyboard and shortcut navigation for closed menulists

>Index: layout/xul/base/public/nsXULPopupManager.h
>+  PRBool HandleKeyboardNavigationInPopup(nsMenuChainItem* aItem,
>+                                         nsMenuPopupFrame* aFrame,
>+                                         nsNavigationDirection aDir);

I would almost rather have two separate methods, one taking a frame (public) and one taking an nsMenuChainItem* (protected) and have them both call this (private) utility method.  They could even inline to do that.  Makes callers simpler to code without having random nsnulls around.

>Index: layout/xul/base/src/nsXULPopupManager.cpp
nsXULPopupManager::HandleKeyboardNavigationInPopup(nsMenuChainItem* 
>+  NS_ASSERTION(item || aFrame, "aFrame and item are both null");

If you do leave the current signature, you need to either assert that !item || !aFrame, or to assert that if both are non-null then aFrame == item->Frame().  In other words, that the frame to work on is well-defined.

And perhaps document what things don't happen if |item| is null.

With that, sr=bzbarsky.
Attachment #272397 - Flags: superreview?(bzbarsky) → superreview+
Attachment #272397 - Flags: review?(neil) → review+
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Flags: in-testsuite? → in-testsuite+
Flags: blocking1.9?
Component: XP Toolkit/Widgets: Menus → XUL
QA Contact: xptoolkit.menus → xptoolkit.widgets
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: