Ok, this is more like it. I did want GEtCharCode after all.

This commit is contained in:
hyatt%netscape.com 1999-07-23 06:01:03 +00:00
Родитель 86ea591e5c
Коммит ed25fb2501
1 изменённых файлов: 6 добавлений и 2 удалений

Просмотреть файл

@ -267,8 +267,12 @@ nsMenuBarListener::KeyPress(nsIDOMEvent* aKeyEvent)
if (uiEvent) {
// See if a letter was pressed.
PRUint32 charCode;
uiEvent->GetKeyCode(&charCode);
if ((active || mAltKeyDown) && (charCode >= NS_VK_A && charCode <= NS_VK_Z)) {
uiEvent->GetCharCode(&charCode);
if ((active || mAltKeyDown) &&
((charCode >= 'a' && charCode <= 'z') ||
(charCode >= 'A' && charCode <= 'Z')))
{
// Do shortcut navigation.
mAltKeyDown = PR_FALSE; // Clear this. ALT presses are irrelevant now.