Fixed the conditions for mouse button click registration on platforms other than Windows.
This commit is contained in:
@@ -177,7 +177,17 @@ RendererStack::mouseReleaseEvent(QMouseEvent *event)
|
||||
return;
|
||||
}
|
||||
if (mouse_capture || (mouse_mode >= 1)) {
|
||||
if ((mouse_mode >= 1) && ((m_monitor_index < 1) || mousedata.mouse_tablet_in_proximity))
|
||||
#ifdef Q_OS_WINDOWS
|
||||
if (((m_monitor_index >= 1) && (mouse_mode >= 1) && mousedata.mouse_tablet_in_proximity) ||
|
||||
((m_monitor_index < 1) && (mouse_mode >= 1)))
|
||||
#else
|
||||
#ifndef __APPLE__
|
||||
if (((m_monitor_index >= 1) && (mouse_mode >= 1) && mousedata.mouse_tablet_in_proximity) ||
|
||||
(m_monitor_index < 1))
|
||||
#else
|
||||
if ((m_monitor_index >= 1) && (mouse_mode >= 1) && mousedata.mouse_tablet_in_proximity)
|
||||
#endif
|
||||
#endif
|
||||
mouse_set_buttons_ex(mouse_get_buttons_ex() & ~event->button());
|
||||
}
|
||||
isMouseDown &= ~1;
|
||||
@@ -188,7 +198,17 @@ RendererStack::mousePressEvent(QMouseEvent *event)
|
||||
{
|
||||
isMouseDown |= 1;
|
||||
if (mouse_capture || (mouse_mode >= 1)) {
|
||||
if ((mouse_mode >= 1) && ((m_monitor_index < 1) || mousedata.mouse_tablet_in_proximity))
|
||||
#ifdef Q_OS_WINDOWS
|
||||
if (((m_monitor_index >= 1) && (mouse_mode >= 1) && mousedata.mouse_tablet_in_proximity) ||
|
||||
((m_monitor_index < 1) && (mouse_mode >= 1)))
|
||||
#else
|
||||
#ifndef __APPLE__
|
||||
if (((m_monitor_index >= 1) && (mouse_mode >= 1) && mousedata.mouse_tablet_in_proximity) ||
|
||||
(m_monitor_index < 1))
|
||||
#else
|
||||
if ((m_monitor_index >= 1) && (mouse_mode >= 1) && mousedata.mouse_tablet_in_proximity)
|
||||
#endif
|
||||
#endif
|
||||
mouse_set_buttons_ex(mouse_get_buttons_ex() | event->button());
|
||||
}
|
||||
event->accept();
|
||||
|
||||
Reference in New Issue
Block a user