зеркало из https://github.com/mozilla/gecko-dev.git
Bug 400854 XUL menulist reacts to command keys with modifiers r=Enn sr=roc
This commit is contained in:
Родитель
6ad1a1eb00
Коммит
a13851633c
|
@ -600,25 +600,24 @@ nsXBLPrototypeHandler::KeyEventMatched(nsIDOMKeyEvent* aKeyEvent,
|
|||
PRUint32 aCharCode,
|
||||
PRBool aIgnoreShiftKey)
|
||||
{
|
||||
if (mDetail == -1)
|
||||
return PR_TRUE; // No filters set up. It's generic.
|
||||
if (mDetail != -1) {
|
||||
// Get the keycode or charcode of the key event.
|
||||
PRUint32 code;
|
||||
|
||||
// Get the keycode or charcode of the key event.
|
||||
PRUint32 code;
|
||||
|
||||
if (mMisc) {
|
||||
if (aCharCode)
|
||||
code = aCharCode;
|
||||
if (mMisc) {
|
||||
if (aCharCode)
|
||||
code = aCharCode;
|
||||
else
|
||||
aKeyEvent->GetCharCode(&code);
|
||||
if (IS_IN_BMP(code))
|
||||
code = ToLowerCase(PRUnichar(code));
|
||||
}
|
||||
else
|
||||
aKeyEvent->GetCharCode(&code);
|
||||
if (IS_IN_BMP(code))
|
||||
code = ToLowerCase(PRUnichar(code));
|
||||
}
|
||||
else
|
||||
aKeyEvent->GetKeyCode(&code);
|
||||
aKeyEvent->GetKeyCode(&code);
|
||||
|
||||
if (code != PRUint32(mDetail))
|
||||
return PR_FALSE;
|
||||
if (code != PRUint32(mDetail))
|
||||
return PR_FALSE;
|
||||
}
|
||||
|
||||
return ModifiersMatchMask(aKeyEvent, aIgnoreShiftKey);
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче