Moved the absolute mouse movement stuff from poll to the mouse event move handler, fixes #3588.
This commit is contained in:
@@ -143,32 +143,6 @@ qt_mouse_capture(int on)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
RendererStack::mousePoll()
|
|
||||||
{
|
|
||||||
if (m_monitor_index >= 1) {
|
|
||||||
if (mouse_mode >= 1) {
|
|
||||||
mouse_x_abs = mousedata.x_abs;
|
|
||||||
mouse_y_abs = mousedata.y_abs;
|
|
||||||
if (!mouse_tablet_in_proximity)
|
|
||||||
mouse_tablet_in_proximity = mousedata.mouse_tablet_in_proximity;
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef Q_OS_WINDOWS
|
|
||||||
if (mouse_mode == 0) {
|
|
||||||
mouse_x_abs = mousedata.x_abs;
|
|
||||||
mouse_y_abs = mousedata.y_abs;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
mouse_x_abs = mousedata.x_abs;
|
|
||||||
mouse_y_abs = mousedata.y_abs;
|
|
||||||
mouse_tablet_in_proximity = mousedata.mouse_tablet_in_proximity;
|
|
||||||
}
|
|
||||||
|
|
||||||
int ignoreNextMouseEvent = 1;
|
int ignoreNextMouseEvent = 1;
|
||||||
void
|
void
|
||||||
RendererStack::mouseReleaseEvent(QMouseEvent *event)
|
RendererStack::mouseReleaseEvent(QMouseEvent *event)
|
||||||
@@ -267,8 +241,29 @@ RendererStack::mouseMoveEvent(QMouseEvent *event)
|
|||||||
ignoreNextMouseEvent = 2;
|
ignoreNextMouseEvent = 2;
|
||||||
oldPos = event->pos();
|
oldPos = event->pos();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
if (m_monitor_index >= 1) {
|
||||||
|
if (mouse_mode >= 1) {
|
||||||
|
mouse_x_abs = mousedata.x_abs;
|
||||||
|
mouse_y_abs = mousedata.y_abs;
|
||||||
|
if (!mouse_tablet_in_proximity)
|
||||||
|
mouse_tablet_in_proximity = mousedata.mouse_tablet_in_proximity;
|
||||||
|
}
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef Q_OS_WINDOWS
|
||||||
|
if (mouse_mode == 0) {
|
||||||
|
mouse_x_abs = mousedata.x_abs;
|
||||||
|
mouse_y_abs = mousedata.y_abs;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
mouse_x_abs = mousedata.x_abs;
|
||||||
|
mouse_y_abs = mousedata.y_abs;
|
||||||
|
mouse_tablet_in_proximity = mousedata.mouse_tablet_in_proximity;
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
|
||||||
|
|||||||
@@ -88,7 +88,6 @@ public slots:
|
|||||||
void blitCommon(int x, int y, int w, int h);
|
void blitCommon(int x, int y, int w, int h);
|
||||||
void blitRenderer(int x, int y, int w, int h);
|
void blitRenderer(int x, int y, int w, int h);
|
||||||
void blitDummy(int x, int y, int w, int h);
|
void blitDummy(int x, int y, int w, int h);
|
||||||
void mousePoll();
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void createRenderer(Renderer renderer);
|
void createRenderer(Renderer renderer);
|
||||||
|
|||||||
Reference in New Issue
Block a user