Adjust down event location when two-finger dragging in TouchExplorer
The bug is happened because the slope between the down event and the move event of the swipe gesture dispatched from TouchExplorer is not smooth. So we also ajust the down event position as the moving event. And we will update the corrupted CTS test case later. Bug: 152931647 Test: none Change-Id: I4d4b1ff2975f440dad0babb87d0af1b6ce348f93
This commit is contained in:
@@ -566,6 +566,7 @@ public class TouchExplorer extends BaseEventStreamTransformation
|
||||
// a given distance perform a drag.
|
||||
mState.startDragging();
|
||||
mDraggingPointerId = pointerId;
|
||||
adjustEventLocationForDrag(event);
|
||||
event.setEdgeFlags(mReceivedPointerTracker.getLastReceivedDownEdgeFlags());
|
||||
mDispatcher.sendMotionEvent(
|
||||
event, MotionEvent.ACTION_DOWN, rawEvent, pointerIdBits, policyFlags);
|
||||
|
||||
Reference in New Issue
Block a user