Changeset View
Changeset View
Standalone View
Standalone View
input_event.cpp
Show All 18 Lines | |||||
19 | *********************************************************************/ | 19 | *********************************************************************/ | ||
20 | #include "input_event.h" | 20 | #include "input_event.h" | ||
21 | 21 | | |||
22 | namespace KWin | 22 | namespace KWin | ||
23 | { | 23 | { | ||
24 | 24 | | |||
25 | MouseEvent::MouseEvent(QEvent::Type type, const QPointF &pos, Qt::MouseButton button, | 25 | MouseEvent::MouseEvent(QEvent::Type type, const QPointF &pos, Qt::MouseButton button, | ||
26 | Qt::MouseButtons buttons, Qt::KeyboardModifiers modifiers, | 26 | Qt::MouseButtons buttons, Qt::KeyboardModifiers modifiers, | ||
27 | quint32 timestamp, LibInput::Device *device) | 27 | quint32 timestamp, const QSizeF &delta, const QSizeF &deltaNonAccelerated, | ||
28 | quint64 timestampMicroseconds, LibInput::Device *device) | ||||
28 | : QMouseEvent(type, pos, pos, button, buttons, modifiers) | 29 | : QMouseEvent(type, pos, pos, button, buttons, modifiers) | ||
30 | , m_delta(delta) | ||||
31 | , m_deltaUnccelerated(deltaNonAccelerated) | ||||
32 | , m_timestampMicroseconds(timestampMicroseconds) | ||||
29 | , m_device(device) | 33 | , m_device(device) | ||
30 | { | 34 | { | ||
31 | setTimestamp(timestamp); | 35 | setTimestamp(timestamp); | ||
32 | } | 36 | } | ||
33 | 37 | | |||
34 | WheelEvent::WheelEvent(const QPointF &pos, qreal delta, Qt::Orientation orientation, Qt::MouseButtons buttons, | 38 | WheelEvent::WheelEvent(const QPointF &pos, qreal delta, Qt::Orientation orientation, Qt::MouseButtons buttons, | ||
35 | Qt::KeyboardModifiers modifiers, quint32 timestamp, LibInput::Device *device) | 39 | Qt::KeyboardModifiers modifiers, quint32 timestamp, LibInput::Device *device) | ||
36 | : QWheelEvent(pos, pos, QPoint(), (orientation == Qt::Horizontal) ? QPoint(delta, 0) : QPoint(0, delta), delta, orientation, buttons, modifiers) | 40 | : QWheelEvent(pos, pos, QPoint(), (orientation == Qt::Horizontal) ? QPoint(delta, 0) : QPoint(0, delta), delta, orientation, buttons, modifiers) | ||
Show All 14 Lines |