Bug 218093. Whitelist more mouse movement events to apply to disabled form controls. r=smaug

This commit is contained in:
Boris Zbarsky 2015-10-16 14:36:19 -04:00
Родитель 9dd6f325b3
Коммит 8d9b5ee469
1 изменённых файлов: 17 добавлений и 1 удалений

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

@ -2457,6 +2457,22 @@ bool
nsGenericHTMLFormElement::IsElementDisabledForEvents(EventMessage aMessage,
nsIFrame* aFrame)
{
switch (aMessage) {
case eMouseMove:
case eMouseOver:
case eMouseOut:
case eMouseEnter:
case eMouseLeave:
case ePointerMove:
case ePointerOver:
case ePointerOut:
case ePointerEnter:
case ePointerLeave:
return false;
default:
break;
}
bool disabled = IsDisabled();
if (!disabled && aFrame) {
const nsStyleUserInterface* uiStyle = aFrame->StyleUserInterface();
@ -2464,7 +2480,7 @@ nsGenericHTMLFormElement::IsElementDisabledForEvents(EventMessage aMessage,
uiStyle->mUserInput == NS_STYLE_USER_INPUT_DISABLED;
}
return disabled && aMessage != eMouseMove;
return disabled;
}
void