mirror of
https://github.com/SFML/SFML.git
synced 2024-11-25 12:51:05 +08:00
Fixed sf::Event::MouseEntered and sf::Event::MouseLeft on Linux
This commit is contained in:
parent
f5b9c7e216
commit
560b741efb
@ -816,19 +816,25 @@ bool WindowImplX11::processEvent(XEvent windowEvent)
|
|||||||
|
|
||||||
// Mouse entered
|
// Mouse entered
|
||||||
case EnterNotify :
|
case EnterNotify :
|
||||||
|
{
|
||||||
|
if (windowEvent.xcrossing.mode == NotifyNormal)
|
||||||
{
|
{
|
||||||
Event event;
|
Event event;
|
||||||
event.type = Event::MouseEntered;
|
event.type = Event::MouseEntered;
|
||||||
pushEvent(event);
|
pushEvent(event);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Mouse left
|
// Mouse left
|
||||||
case LeaveNotify :
|
case LeaveNotify :
|
||||||
|
{
|
||||||
|
if (windowEvent.xcrossing.mode == NotifyNormal)
|
||||||
{
|
{
|
||||||
Event event;
|
Event event;
|
||||||
event.type = Event::MouseLeft;
|
event.type = Event::MouseLeft;
|
||||||
pushEvent(event);
|
pushEvent(event);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user