mirror of
https://github.com/AngelAuraMC/Amethyst-Android.git
synced 2025-09-18 09:07:48 -04:00
Fix[touch]: pressing a passthrough button isn't considered a "cold start"
This commit is contained in:
parent
d676ca8d6a
commit
e7265671c6
@ -40,6 +40,7 @@ public class InGUIEventProcessor implements TouchEventProcessor {
|
||||
}
|
||||
break;
|
||||
case MotionEvent.ACTION_UP:
|
||||
mTracker.cancelTracking();
|
||||
disableMouse();
|
||||
}
|
||||
return true;
|
||||
|
@ -63,6 +63,7 @@ public class InGameEventProcessor implements TouchEventProcessor {
|
||||
break;
|
||||
case MotionEvent.ACTION_UP:
|
||||
case MotionEvent.ACTION_CANCEL:
|
||||
mTracker.cancelTracking();
|
||||
cancelGestures(false);
|
||||
}
|
||||
return true;
|
||||
|
@ -17,6 +17,10 @@ public class PointerTracker {
|
||||
mLastY = motionEvent.getY();
|
||||
}
|
||||
|
||||
public void cancelTracking() {
|
||||
mColdStart = true;
|
||||
}
|
||||
|
||||
public int trackEvent(MotionEvent motionEvent) {
|
||||
int trackedPointerIndex = motionEvent.findPointerIndex(mTrackedPointerId);
|
||||
int pointerCount = motionEvent.getPointerCount();
|
||||
|
Loading…
x
Reference in New Issue
Block a user