diff --git a/src/SFML/Window/Unix/DRM/InputImplUDev.cpp b/src/SFML/Window/Unix/DRM/InputImplUDev.cpp index 6003a666..c3ffd76a 100644 --- a/src/SFML/Window/Unix/DRM/InputImplUDev.cpp +++ b/src/SFML/Window/Unix/DRM/InputImplUDev.cpp @@ -469,8 +469,18 @@ namespace } else if ( ie.type == EV_ABS ) { + bool posChange = false; switch ( ie.code ) { + case ABS_X: + mousePos.x = ie.value; + posChange = true; + break; + + case ABS_Y: + mousePos.y = ie.value; + posChange = true; + break; case ABS_MT_SLOT: currentSlot = ie.value; touchFd = *itr; @@ -488,6 +498,13 @@ namespace touchFd = *itr; break; } + if ( posChange ) + { + ev.type = sf::Event::MouseMoved; + ev.mouseMove.x = mousePos.x; + ev.mouseMove.y = mousePos.y; + return true; + } } else if ( ie.type == EV_SYN && ie.code == SYN_REPORT && *itr == touchFd)