diff --git a/src/common/gui/CCursorHidingControl.cpp b/src/common/gui/CCursorHidingControl.cpp index 8fefda3e9a8..241586e3c96 100644 --- a/src/common/gui/CCursorHidingControl.cpp +++ b/src/common/gui/CCursorHidingControl.cpp @@ -43,7 +43,7 @@ CMouseEventResult CCursorHidingControl::onMouseMoved(CPoint& where, const CButto double dy = where.y - _lastPos.y; _lastPos = where; - if (_isDetatched) + if (_isDetatched && !buttons.isTouch()) { double scaling = getMouseDeltaScaling(where, buttons); @@ -57,22 +57,15 @@ CMouseEventResult CCursorHidingControl::onMouseMoved(CPoint& where, const CButto onMouseMoveDelta(where, buttons, dx, dy); #if WINDOWS - if (_isDetatched) + if (_isDetatched && !buttons.isTouch()) { - // test for touch. If we are in a touch screen this cursor reset seems like a messy flip. See #1443 - int value = GetSystemMetrics(SM_DIGITIZER); - bool hasTouch = ( value & ( NID_INTEGRATED_TOUCH | NID_EXTERNAL_TOUCH ) ) ? true : false; - - if (!hasTouch) - { - double ddx = where.x - _detachPos.x; - double ddy = where.y - _detachPos.y; - double d = sqrt(ddx * ddx + ddy * ddy); - if (d > 10 && SetCursorPos(_hideX, _hideY)) - { - _lastPos = _detachPos; - } - } + double ddx = where.x - _detachPos.x; + double ddy = where.y - _detachPos.y; + double d = sqrt(ddx * ddx + ddy * ddy); + if (d > 10 && SetCursorPos(_hideX, _hideY)) + { + _lastPos = _detachPos; + } } #endif diff --git a/src/common/gui/CSurgeSlider.cpp b/src/common/gui/CSurgeSlider.cpp index 872c8e01c19..663b0d86109 100644 --- a/src/common/gui/CSurgeSlider.cpp +++ b/src/common/gui/CSurgeSlider.cpp @@ -465,6 +465,9 @@ double CSurgeSlider::getMouseDeltaScaling(CPoint& where, const CButtonState& but break; } + if (buttons.isTouch()) + rate = 1.0; + if (buttons & kRButton) rate *= 0.1; if (buttons & kShift) diff --git a/vstgui.surge b/vstgui.surge index 8b37ab51867..fdc321ee281 160000 --- a/vstgui.surge +++ b/vstgui.surge @@ -1 +1 @@ -Subproject commit 8b37ab518673b5a3857eee98a10e0a4deff19350 +Subproject commit fdc321ee2819397f9845f1a47cf3594cb8fd5e1b