Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[touch] fix missing call to OnTouchGestureStart() from CGenericTouchI…

…nputHandler if only the secondary pointer moved
  • Loading branch information...
commit 2cbf2c6f3c6be73d99ad4c70aafb5b23e36ad31b 1 parent 8d76aa2
Sascha Montellese Montellese authored
Showing with 13 additions and 3 deletions.
  1. +13 −3 xbmc/input/touch/generic/GenericTouchInputHandler.cpp
16 xbmc/input/touch/generic/GenericTouchInputHandler.cpp
View
@@ -212,9 +212,17 @@ bool CGenericTouchInputHandler::HandleTouchInput(TouchInput event, float x, floa
m_gestureState == TouchGestureMultiTouchDone)
break;
- triggerDetectors(event, pointer);
+ bool moving = false;
+ for (unsigned int index = 0; index < TOUCH_MAX_POINTERS; index++)
+ {
+ if (m_pointers[index].valid() && m_pointers[index].moving)
+ {
+ moving = true;
+ break;
+ }
+ }
- if (m_pointers[pointer].moving)
+ if (moving)
{
m_holdTimer->Stop();
@@ -223,6 +231,8 @@ bool CGenericTouchInputHandler::HandleTouchInput(TouchInput event, float x, floa
result = OnTouchGestureStart(m_pointers[pointer].down.x, m_pointers[pointer].down.y);
}
+ triggerDetectors(event, pointer);
+
if (m_gestureState == TouchGestureSingleTouch)
{
// Check if the touch has moved far enough to count as movement
@@ -260,7 +270,7 @@ bool CGenericTouchInputHandler::HandleTouchInput(TouchInput event, float x, floa
}
else if (m_gestureState == TouchGestureMultiTouch)
{
- if (m_pointers[pointer].moving)
+ if (moving)
result = OnMultiTouchMove(x, y,offsetX, offsetY, velocityX, velocityY, pointer);
}
else
Please sign in to comment.
Something went wrong with that request. Please try again.