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

Commit 2341fd66 authored by Jeff Brown's avatar Jeff Brown Committed by Android Git Automerger
Browse files

am 26d5786f: am 9c37447e: Merge "Fix pointer index when splitting secondary...

am 26d5786f: am 9c37447e: Merge "Fix pointer index when splitting secondary pointers." into gingerbread

Merge commit '26d5786fb1a43d82b40fa908e1220a018b748c93'

* commit '26d5786fb1a43d82b40fa908e1220a018b748c93':
  Fix pointer index when splitting secondary pointers.
parents 2b086f71 1f1889e8
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -1916,6 +1916,14 @@ InputDispatcher::splitMotionEvent(const MotionEntry* originalMotionEntry, BitSet
                // The first/last pointer went down/up.
                action = maskedAction == AMOTION_EVENT_ACTION_POINTER_DOWN
                        ? AMOTION_EVENT_ACTION_DOWN : AMOTION_EVENT_ACTION_UP;
            } else {
                // A secondary pointer went down/up.
                uint32_t splitPointerIndex = 0;
                while (pointerId != splitPointerIds[splitPointerIndex]) {
                    splitPointerIndex += 1;
                }
                action = maskedAction | (splitPointerIndex
                        << AMOTION_EVENT_ACTION_POINTER_INDEX_SHIFT);
            }
        } else {
            // An unrelated pointer changed.