Home
last modified time | relevance | path

Searched refs:pointerIndex (Results 1 – 25 of 39) sorted by relevance

12

/frameworks/native/include/input/
DInput.h421 inline const PointerProperties* getPointerProperties(size_t pointerIndex) const { in getPointerProperties() argument
422 return &mPointerProperties[pointerIndex]; in getPointerProperties()
425 inline int32_t getPointerId(size_t pointerIndex) const { in getPointerId() argument
426 return mPointerProperties[pointerIndex].id; in getPointerId()
429 inline int32_t getToolType(size_t pointerIndex) const { in getToolType() argument
430 return mPointerProperties[pointerIndex].toolType; in getToolType()
435 const PointerCoords* getRawPointerCoords(size_t pointerIndex) const;
437 float getRawAxisValue(int32_t axis, size_t pointerIndex) const;
439 inline float getRawX(size_t pointerIndex) const { in getRawX() argument
440 return getRawAxisValue(AMOTION_EVENT_AXIS_X, pointerIndex); in getRawX()
[all …]
/frameworks/support/v4/java/android/support/v4/view/
DMotionEventCompat.java32 public int getPointerId(MotionEvent event, int pointerIndex); in getPointerId() argument
33 public float getX(MotionEvent event, int pointerIndex); in getX() argument
34 public float getY(MotionEvent event, int pointerIndex); in getY() argument
38 float getAxisValue(MotionEvent event, int axis, int pointerIndex); in getAxisValue() argument
55 public int getPointerId(MotionEvent event, int pointerIndex) { in getPointerId() argument
56 if (pointerIndex == 0) { in getPointerId()
63 public float getX(MotionEvent event, int pointerIndex) { in getX() argument
64 if (pointerIndex == 0) { in getX()
70 public float getY(MotionEvent event, int pointerIndex) { in getY() argument
71 if (pointerIndex == 0) { in getY()
[all …]
/frameworks/base/core/java/android/view/
DMotionEvent.java1477 private static native int nativeGetPointerId(long nativePtr, int pointerIndex); in nativeGetPointerId() argument
1478 private static native int nativeGetToolType(long nativePtr, int pointerIndex); in nativeGetToolType() argument
1484 int axis, int pointerIndex, int historyPos); in nativeGetRawAxisValue() argument
1486 int axis, int pointerIndex, int historyPos); in nativeGetAxisValue() argument
1488 int pointerIndex, int historyPos, PointerCoords outPointerCoords); in nativeGetPointerCoords() argument
1490 int pointerIndex, PointerProperties outPointerProperties); in nativeGetPointerProperties() argument
2076 public final int getPointerId(int pointerIndex) { in getPointerId() argument
2077 return nativeGetPointerId(mNativePtr, pointerIndex); in getPointerId()
2094 public final int getToolType(int pointerIndex) { in getToolType() argument
2095 return nativeGetToolType(mNativePtr, pointerIndex); in getToolType()
[all …]
/frameworks/support/v4/eclair/android/support/v4/view/
DMotionEventCompatEclair.java28 public static int getPointerId(MotionEvent event, int pointerIndex) { in getPointerId() argument
29 return event.getPointerId(pointerIndex); in getPointerId()
31 public static float getX(MotionEvent event, int pointerIndex) { in getX() argument
32 return event.getX(pointerIndex); in getX()
34 public static float getY(MotionEvent event, int pointerIndex) { in getY() argument
35 return event.getY(pointerIndex); in getY()
/frameworks/base/services/accessibility/java/com/android/server/accessibility/
DGestureUtils.java38 public static double computeDistance(MotionEvent first, MotionEvent second, int pointerIndex) { in computeDistance() argument
39 return MathUtils.dist(first.getX(pointerIndex), first.getY(pointerIndex), in computeDistance()
40 second.getX(pointerIndex), second.getY(pointerIndex)); in computeDistance()
DAutoclickController.java387 final int pointerIndex = mLastMotionEvent.getActionIndex(); in cacheLastEvent() local
388 mLastMotionEvent.getPointerCoords(pointerIndex, mAnchorCoords); in cacheLastEvent()
410 final int pointerIndex = event.getActionIndex(); in detectMovement() local
411 float deltaX = mAnchorCoords.x - event.getX(pointerIndex); in detectMovement()
412 float deltaY = mAnchorCoords.y - event.getY(pointerIndex); in detectMovement()
425 final int pointerIndex = mLastMotionEvent.getActionIndex(); in sendClick() local
432 mLastMotionEvent.getPointerProperties(pointerIndex, mTempPointerProperties[0]); in sendClick()
438 mLastMotionEvent.getPointerCoords(pointerIndex, mTempPointerCoords[0]); in sendClick()
DTouchExplorer.java372 final int pointerIndex = event.getActionIndex(); in onDoubleTapAndHold() local
373 final int pointerId = event.getPointerId(pointerIndex); in onDoubleTapAndHold()
383 mLongPressingPointerDeltaX = (int) event.getX(pointerIndex) - clickLocation.x; in onDoubleTapAndHold()
384 mLongPressingPointerDeltaY = (int) event.getY(pointerIndex) - clickLocation.y; in onDoubleTapAndHold()
410 final int pointerIndex = event.getActionIndex(); in onDoubleTap() local
411 final int pointerId = event.getPointerId(pointerIndex); in onDoubleTap()
424 event.getPointerProperties(pointerIndex, properties[0]); in onDoubleTap()
543 final int pointerIndex = event.findPointerIndex(pointerId); in handleMotionEventStateTouchExploring() local
576 pointerId) - rawEvent.getX(pointerIndex); in handleMotionEventStateTouchExploring()
578 pointerId) - rawEvent.getY(pointerIndex); in handleMotionEventStateTouchExploring()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/phone/
DHeadsUpTouchHelper.java66 int pointerIndex = event.findPointerIndex(mTrackingPointer); in onInterceptTouchEvent() local
67 if (pointerIndex < 0) { in onInterceptTouchEvent()
68 pointerIndex = 0; in onInterceptTouchEvent()
69 mTrackingPointer = event.getPointerId(pointerIndex); in onInterceptTouchEvent()
71 final float x = event.getX(pointerIndex); in onInterceptTouchEvent()
72 final float y = event.getY(pointerIndex); in onInterceptTouchEvent()
DPanelView.java238 int pointerIndex = event.findPointerIndex(mTrackingPointer); in onTouchEvent() local
239 if (pointerIndex < 0) { in onTouchEvent()
240 pointerIndex = 0; in onTouchEvent()
241 mTrackingPointer = event.getPointerId(pointerIndex); in onTouchEvent()
243 final float x = event.getX(pointerIndex); in onTouchEvent()
244 final float y = event.getY(pointerIndex); in onTouchEvent()
457 int pointerIndex = event.findPointerIndex(mTrackingPointer); in onInterceptTouchEvent() local
458 if (pointerIndex < 0) { in onInterceptTouchEvent()
459 pointerIndex = 0; in onInterceptTouchEvent()
460 mTrackingPointer = event.getPointerId(pointerIndex); in onInterceptTouchEvent()
[all …]
DNotificationPanelView.java588 int pointerIndex = event.findPointerIndex(mTrackingPointer); in onQsIntercept() local
589 if (pointerIndex < 0) { in onQsIntercept()
590 pointerIndex = 0; in onQsIntercept()
591 mTrackingPointer = event.getPointerId(pointerIndex); in onQsIntercept()
593 final float x = event.getX(pointerIndex); in onQsIntercept()
594 final float y = event.getY(pointerIndex); in onQsIntercept()
865 int pointerIndex = event.findPointerIndex(mTrackingPointer); in onQsTouch() local
866 if (pointerIndex < 0) { in onQsTouch()
867 pointerIndex = 0; in onQsTouch()
868 mTrackingPointer = event.getPointerId(pointerIndex); in onQsTouch()
[all …]
/frameworks/base/core/jni/
Dandroid_view_MotionEvent.cpp158 static bool validatePointerIndex(JNIEnv* env, jint pointerIndex, size_t pointerCount) { in validatePointerIndex() argument
159 if (pointerIndex < 0 || size_t(pointerIndex) >= pointerCount) { in validatePointerIndex()
568 jlong nativePtr, jint pointerIndex) { in android_view_MotionEvent_nativeGetPointerId() argument
571 if (!validatePointerIndex(env, pointerIndex, pointerCount)) { in android_view_MotionEvent_nativeGetPointerId()
574 return event->getPointerId(pointerIndex); in android_view_MotionEvent_nativeGetPointerId()
578 jlong nativePtr, jint pointerIndex) { in android_view_MotionEvent_nativeGetToolType() argument
581 if (!validatePointerIndex(env, pointerIndex, pointerCount)) { in android_view_MotionEvent_nativeGetToolType()
584 return event->getToolType(pointerIndex); in android_view_MotionEvent_nativeGetToolType()
614 jlong nativePtr, jint axis, jint pointerIndex, jint historyPos) { in android_view_MotionEvent_nativeGetRawAxisValue() argument
617 if (!validatePointerIndex(env, pointerIndex, pointerCount)) { in android_view_MotionEvent_nativeGetRawAxisValue()
[all …]
/frameworks/opt/photoviewer/src/com/android/ex/photo/
DPhotoViewPager.java139 final int pointerIndex = in onInterceptTouchEvent() local
141 final float x = MotionEventCompat.getX(ev, pointerIndex); in onInterceptTouchEvent()
168 final int pointerIndex = MotionEventCompat.getActionIndex(ev); in onInterceptTouchEvent() local
169 final int pointerId = MotionEventCompat.getPointerId(ev, pointerIndex); in onInterceptTouchEvent()
172 final int newPointerIndex = pointerIndex == 0 ? 1 : 0; in onInterceptTouchEvent()
/frameworks/native/libs/input/
DInput.cpp288 const PointerCoords* MotionEvent::getRawPointerCoords(size_t pointerIndex) const { in getRawPointerCoords()
289 return &mSamplePointerCoords[getHistorySize() * getPointerCount() + pointerIndex]; in getRawPointerCoords()
292 float MotionEvent::getRawAxisValue(int32_t axis, size_t pointerIndex) const { in getRawAxisValue()
293 return getRawPointerCoords(pointerIndex)->getAxisValue(axis); in getRawAxisValue()
296 float MotionEvent::getAxisValue(int32_t axis, size_t pointerIndex) const { in getAxisValue()
297 float value = getRawPointerCoords(pointerIndex)->getAxisValue(axis); in getAxisValue()
308 size_t pointerIndex, size_t historicalIndex) const { in getHistoricalRawPointerCoords() argument
309 return &mSamplePointerCoords[historicalIndex * getPointerCount() + pointerIndex]; in getHistoricalRawPointerCoords()
312 float MotionEvent::getHistoricalRawAxisValue(int32_t axis, size_t pointerIndex, in getHistoricalRawAxisValue() argument
314 return getHistoricalRawPointerCoords(pointerIndex, historicalIndex)->getAxisValue(axis); in getHistoricalRawAxisValue()
[all …]
/frameworks/support/v4/honeycomb_mr1/android/support/v4/view/
DMotionEventCompatHoneycombMr1.java29 static float getAxisValue(MotionEvent event, int axis, int pointerIndex) { in getAxisValue() argument
30 return event.getAxisValue(axis, pointerIndex); in getAxisValue()
/frameworks/support/v4/java/android/support/v4/widget/
DSwipeRefreshLayout.java983 int pointerIndex = -1; in onTouchEvent() local
1001 pointerIndex = MotionEventCompat.findPointerIndex(ev, mActivePointerId); in onTouchEvent()
1002 if (pointerIndex < 0) { in onTouchEvent()
1007 final float y = MotionEventCompat.getY(ev, pointerIndex); in onTouchEvent()
1019 pointerIndex = MotionEventCompat.getActionIndex(ev); in onTouchEvent()
1020 if (pointerIndex < 0) { in onTouchEvent()
1024 mActivePointerId = MotionEventCompat.getPointerId(ev, pointerIndex); in onTouchEvent()
1033 pointerIndex = MotionEventCompat.findPointerIndex(ev, mActivePointerId); in onTouchEvent()
1034 if (pointerIndex < 0) { in onTouchEvent()
1039 final float y = MotionEventCompat.getY(ev, pointerIndex); in onTouchEvent()
[all …]
/frameworks/base/services/core/java/com/android/server/policy/
DSystemGesturesPointerEventListener.java159 private void captureDown(MotionEvent event, int pointerIndex) { in captureDown() argument
160 final int pointerId = event.getPointerId(pointerIndex); in captureDown()
163 " down pointerIndex=" + pointerIndex + " trackingIndex=" + i); in captureDown()
165 mDownX[i] = event.getX(pointerIndex); in captureDown()
166 mDownY[i] = event.getY(pointerIndex); in captureDown()
/frameworks/base/core/java/com/android/internal/widget/
DSwipeDismissLayout.java206 int pointerIndex = ev.findPointerIndex(mActiveTouchId); in onInterceptTouchEvent() local
207 if (pointerIndex == -1) { in onInterceptTouchEvent()
213 float x = ev.getX(pointerIndex); in onInterceptTouchEvent()
214 float y = ev.getY(pointerIndex); in onInterceptTouchEvent()
DResolverDrawerLayout.java333 final int pointerIndex = ev.getActionIndex(); in onTouchEvent() local
334 final int pointerId = ev.getPointerId(pointerIndex); in onTouchEvent()
336 mInitialTouchX = ev.getX(pointerIndex); in onTouchEvent()
337 mInitialTouchY = mLastTouchY = ev.getY(pointerIndex); in onTouchEvent()
394 final int pointerIndex = ev.getActionIndex();
395 final int pointerId = ev.getPointerId(pointerIndex);
399 final int newPointerIndex = pointerIndex == 0 ? 1 : 0;
/frameworks/rs/java/tests/Balls/src/com/example/android/rs/balls/
DBallsView.java82 int pointerIndex = ev.getActionIndex(); in onTouchEvent() local
83 int pointerId = ev.getPointerId(pointerIndex); in onTouchEvent()
/frameworks/support/v7/recyclerview/src/android/support/v7/widget/helper/
DItemTouchHelper.java394 final int pointerIndex = MotionEventCompat.getActionIndex(event);
395 final int pointerId = MotionEventCompat.getPointerId(event, pointerIndex);
399 final int newPointerIndex = pointerIndex == 0 ? 1 : 0;
401 updateDxDy(event, mSelectedFlags, pointerIndex);
925 final int pointerIndex = MotionEventCompat.findPointerIndex(motionEvent, mActivePointerId); in findSwipedView() local
926 final float dx = MotionEventCompat.getX(motionEvent, pointerIndex) - mInitialTouchX; in findSwipedView()
927 final float dy = MotionEventCompat.getY(motionEvent, pointerIndex) - mInitialTouchY; in findSwipedView()
949 private boolean checkSelectForSwipe(int action, MotionEvent motionEvent, int pointerIndex) { in checkSelectForSwipe() argument
972 final float x = MotionEventCompat.getX(motionEvent, pointerIndex); in checkSelectForSwipe()
973 final float y = MotionEventCompat.getY(motionEvent, pointerIndex); in checkSelectForSwipe()
[all …]
/frameworks/support/design/src/android/support/design/widget/
DHeaderBehavior.java86 final int pointerIndex = MotionEventCompat.findPointerIndex(ev, activePointerId); in onInterceptTouchEvent() local
87 if (pointerIndex == -1) { in onInterceptTouchEvent()
91 final int y = (int) MotionEventCompat.getY(ev, pointerIndex); in onInterceptTouchEvent()
/frameworks/base/docs/html/training/gestures/
Dscale.jd117 final int pointerIndex = MotionEventCompat.getActionIndex(ev);
118 final float x = MotionEventCompat.getX(ev, pointerIndex);
119 final float y = MotionEventCompat.getY(ev, pointerIndex);
131 final int pointerIndex =
134 final float x = MotionEventCompat.getX(ev, pointerIndex);
135 final float y = MotionEventCompat.getY(ev, pointerIndex);
165 final int pointerIndex = MotionEventCompat.getActionIndex(ev);
166 final int pointerId = MotionEventCompat.getPointerId(ev, pointerIndex);
171 final int newPointerIndex = pointerIndex == 0 ? 1 : 0;
/frameworks/base/packages/SystemUI/src/com/android/systemui/recents/views/
DTaskStackViewTouchHandler.java312 int pointerIndex = ev.getActionIndex(); in handleTouchEvent() local
313 int pointerId = ev.getPointerId(pointerIndex); in handleTouchEvent()
316 final int newPointerIndex = (pointerIndex == 0) ? 1 : 0; in handleTouchEvent()
318 mDownX = (int) ev.getX(pointerIndex); in handleTouchEvent()
319 mDownY = (int) ev.getY(pointerIndex); in handleTouchEvent()
/frameworks/base/core/java/android/widget/
DStackView.java631 int pointerIndex = ev.findPointerIndex(mActivePointerId); in onInterceptTouchEvent() local
632 if (pointerIndex == INVALID_POINTER) { in onInterceptTouchEvent()
637 float newY = ev.getY(pointerIndex); in onInterceptTouchEvent()
713 int pointerIndex = ev.findPointerIndex(mActivePointerId);
714 if (pointerIndex == INVALID_POINTER) {
720 float newY = ev.getY(pointerIndex);
721 float newX = ev.getX(pointerIndex);
811 int pointerIndex = ev.findPointerIndex(mActivePointerId);
812 float newY = ev.getY(pointerIndex);
DHorizontalScrollView.java486 final int pointerIndex = ev.findPointerIndex(activePointerId); in onInterceptTouchEvent() local
487 if (pointerIndex == -1) { in onInterceptTouchEvent()
493 final int x = (int) ev.getX(pointerIndex); in onInterceptTouchEvent()
704 final int pointerIndex = (ev.getAction() & MotionEvent.ACTION_POINTER_INDEX_MASK) >> in onSecondaryPointerUp() local
706 final int pointerId = ev.getPointerId(pointerIndex); in onSecondaryPointerUp()
711 final int newPointerIndex = pointerIndex == 0 ? 1 : 0; in onSecondaryPointerUp()

12