Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 2b342f0a authored by Adam Powell's avatar Adam Powell
Browse files

Allow ViewGroup to split MotionEvents to multiple targets during dispatch.

Use the layout xml attribute splitMotionEvents="true" or the ViewGroup
method setMotionEventSplittingEnabled(true) to enable motion event
splitting. Rules for splitting are as follows:

* Splitting is enabled per ViewGroup. When splitting is enabled any
  MotionEvent dispatched to that ViewGroup can potentially be split
  into several and dispatched to children independently.

* Each pointer is assigned a target child view when the ACTION_DOWN or
  ACTION_POINTER_DOWN event is received. That will be the pointer's
  target until it goes up, the target returns false from onTouchEvent,
  or the MotionEvents are intercepted.

* Multiple pointers may be assigned to the same target. All pointer
  data sent to a target are bundled into a single MotionEvent. Child
  views do not need to be aware that splitting has occurred.

Change-Id: I993f838e2f6b455da9812f4742a016dfcd1c4cc9
parent 8a44bb23
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment