Platform/Window: Revert wrong mouse position fix
This commit is contained in:
parent
b83a9b60e7
commit
1b80ad5f02
|
|
@ -58,8 +58,7 @@ namespace Nz
|
|||
m_parent(parent),
|
||||
m_smoothScrolling(false),
|
||||
m_mousePos(0, 0),
|
||||
m_keyRepeat(true),
|
||||
m_lastSequence(0)
|
||||
m_keyRepeat(true)
|
||||
{
|
||||
std::memset(&m_size_hints, 0, sizeof(m_size_hints));
|
||||
}
|
||||
|
|
@ -1246,11 +1245,9 @@ namespace Nz
|
|||
xcb_motion_notify_event_t* motionNotifyEvent = (xcb_motion_notify_event_t*)windowEvent;
|
||||
|
||||
// We use the sequence to determine whether the motion is linked to a Mouse::SetPosition
|
||||
if ((m_mousePos.x == motionNotifyEvent->event_x && m_mousePos.y == motionNotifyEvent->event_y) || m_lastSequence == motionNotifyEvent->sequence)
|
||||
if (m_mousePos.x == motionNotifyEvent->event_x && m_mousePos.y == motionNotifyEvent->event_y)
|
||||
break;
|
||||
|
||||
m_lastSequence = motionNotifyEvent->sequence;
|
||||
|
||||
WindowEvent event;
|
||||
event.type = Nz::WindowEventType_MouseMoved;
|
||||
event.mouseMove.deltaX = motionNotifyEvent->event_x - m_mousePos.x;
|
||||
|
|
|
|||
|
|
@ -113,7 +113,6 @@ namespace Nz
|
|||
bool m_threadActive;
|
||||
Vector2i m_mousePos;
|
||||
bool m_keyRepeat;
|
||||
uint16_t m_lastSequence;
|
||||
|
||||
struct
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue