Closed Bug 95250 Opened 24 years ago Closed 22 years ago

Cannot use shortcuts when menus are dropped down

Categories

(Core :: DOM: UI Events & Focus Handling, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: jblanco, Assigned: hyatt)

Details

Steps to recreate: -open browser and hit Alt+F -the File menu will drop down showing that Ctrl+W is the shortcut to close the browser and W is the mnemonic/access key to work on/offline -now hit Ctrl+W to close the window -the window will not close and you will now be working off/online -only the access keys work when menus are dropped down Expected Result - Hitting Ctrl+W should close the window. Hit F9 while a menu is dropped down, the sidebar should open/close, but nothing happens. This is a problem with all shortcuts except those using Alt, like Alt+Home, which takes you to the home page. I notice the code that affects this is in nsMenuListener.cpp. In the KeyDown function, it checks to see if the menuAccessKey was pressed -which is Alt on windows and OS/2- if so, it will make sure no other key (ctrl, shift, meta) was pressed also. DismissChain gets called when just Alt is pressed which will kill the menu and execute the shortcut. Should this function also be checking for Shortcuts?(Ctrl+char, function keys, Del)
I have a similar problem: while loading a page, the accesskey do not work (ctrl-n for example). Oddly, using the menu File->New Nav Window works. Maybe this is a more general problem with key events handling?
window2000 - buildID: 2001-08-22-06trunk Following are the shortcut keys I see working when the File menu drop down is opened using alt+F :- ctrl+p => this opens up the print dialog box ctrl+n => this opens up the new browser window ctrl+shift+L => this opens up the 'open web location' dialog box ctrl+O => open file dialog box displayed the following shortcut keys do not function as desired when the File menu drop down is opened using alt+F :- ctrl+W ctrl+Q ctrl+E ctrl+S => this opens the 'search' drop down menu -- this is wrong ================================= following do not work when 'View' drop down menu is opened with alt+V:- F9 ctrl+U =================================
The reason Ctrl+ p, l, n, o work as shortcuts is because if you just hit p, l, n, or o (without hitting ctrl) they work as the accesskeys. Using Ctrl+S to see if the save file dialog comes up with the File menu pulled down isn't a good test case for this. You need to do Ctrl+S with the Bookmarks or Go menu pulled down because there is no 's' as an accesskey(mnemonic).
->hyatt, xpmenus shouldn't be eating the events
Assignee: joki → hyatt
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla1.1
QA Contact: madhur → rakeshmishra
QA Contact: rakeshmishra → trix
Keywords: nsbeta1
adt: nsbeta1-
Keywords: nsbeta1nsbeta1-
I don't know about other OS's, but under Windows it is not common to have the accelerators active while the menu is open. With the menu open, key processing is generally handled by the system's menu-event loop, not by the application. Under Windows 2000, I just tried the Windows Explorer's Edit menu -- the hotkeys for Undo, Copy, Cut, Paste (ctrl-z, ctrl-c, ctrl-x, ctrl-v) were not active while the menu was open (in fact, they beeped when pressed), altho ctrl-a for Select All closed the menu and selected the contents. As indicated in comment 3, when the menu is open, each menu item should have an underlined mnemonic, and pressing the associated key (with or without the Ctrl) triggers the action. If the mnemonic happens to match the accelerator, then the accelerator will work if the menu is open. Recommend WontFix.
I agree WONTFIX if Brade and Akkana also agree for Mac and Unix behavior.
Same on linux, at least for gtk (gimp 1.2) and kde (kedit) -- accelerators are not active while a menu is dropped down.
This works fine on Netscape 7 on OSX 10.2.x. I can click on the File menu and press command-O and get the open dialog as expected. It also works for iChat. Removing self from cc list since this isn't a Mac bug.
Resolving WONTFIX per comments from Akkana and Brade.
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → WONTFIX
Target Milestone: mozilla1.1alpha → M1
Component: Event Handling → User events and focus handling
You need to log in before you can comment on or make changes to this bug.