We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a8b0550 commit dff1c98Copy full SHA for dff1c98
nestedscrollwebview/src/main/java/com/telefonica/nestedscrollwebview/NestedScrollWebView.java
@@ -365,6 +365,13 @@ public void onNestedTouchEvent(@NonNull MotionEvent ev) {
365
}
366
case MotionEvent.ACTION_POINTER_UP:
367
onSecondaryPointerUp(ev);
368
+ /* Code not present on NestedScrollView code.
369
+ Prevent crash on last motion update due an invalid pointerId. */
370
+ if (ev.findPointerIndex(mActivePointerId) == -1) {
371
+ Log.e(TAG, "Invalid pointerId=" + mActivePointerId + " in onTouchEvent for ACTION_POINTER_UP");
372
+ break;
373
+ }
374
+ /* End of code not present on NestedScrollView code. */
375
mLastMotionY = (int) ev.getY(ev.findPointerIndex(mActivePointerId));
376
break;
377
0 commit comments