summaryrefslogtreecommitdiffstats
path: root/src/platformsupport/input
diff options
context:
space:
mode:
authorCathy Park <cathy.park@lge.com>2021-08-02 17:53:59 +0900
committerJaeyoon Jung <jaeyoon.jung@lge.com>2021-08-11 12:38:35 +0000
commit3727683bd5f57666926603b84bccdf24d3839c98 (patch)
tree4586df46828987783c26f69c89d0c98109a4c459 /src/platformsupport/input
parentbb49d2ec026d72db8d5ae678605d6fb9f94a9e0f (diff)
Fix button type to update coordinates when dragging
A move position (x,y) can be delivered to the MouseArea only if button is Qt::NoButton during mouse move (dragging). Otherwise mouse move does not cause positionChanged in MouseArea. Task-number: QTBUG-95453 Pick-to: 6.1 6.2 Change-Id: I298943dc4f6f30714e940f4029c62dd52c176b93 Reviewed-by: Jaeyoon Jung <jaeyoon.jung@lge.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Diffstat (limited to 'src/platformsupport/input')
-rw-r--r--src/platformsupport/input/evdevmouse/qevdevmousehandler.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/platformsupport/input/evdevmouse/qevdevmousehandler.cpp b/src/platformsupport/input/evdevmouse/qevdevmousehandler.cpp
index 5d6f20bd1a..2012022656 100644
--- a/src/platformsupport/input/evdevmouse/qevdevmousehandler.cpp
+++ b/src/platformsupport/input/evdevmouse/qevdevmousehandler.cpp
@@ -204,7 +204,10 @@ void QEvdevMouseHandler::sendMouseEvent()
m_prevInvalid = false;
}
- emit handleMouseEvent(x, y, m_abs, m_buttons, m_button, m_eventType);
+ if (m_eventType == QEvent::MouseMove)
+ emit handleMouseEvent(x, y, m_abs, m_buttons, Qt::NoButton, m_eventType);
+ else
+ emit handleMouseEvent(x, y, m_abs, m_buttons, m_button, m_eventType);
m_prevx = m_x;
m_prevy = m_y;