Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

java.lang.IllegalArgumentException: pointerIndex out of range #7

Open
jhwsx opened this issue Oct 9, 2019 · 2 comments
Open

java.lang.IllegalArgumentException: pointerIndex out of range #7

jhwsx opened this issue Oct 9, 2019 · 2 comments

Comments

@jhwsx
Copy link

jhwsx commented Oct 9, 2019

1,错误日志如下:

java.lang.IllegalArgumentException: pointerIndex out of range
    at android.view.MotionEvent.null nativeGetAxisValue(null)(MotionEvent.java)
    at android.view.MotionEvent.null getX(null)(MotionEvent.java:2201)
    at androidx.viewpager.widget.ViewPager.boolean onTouchEvent(android.view.MotionEvent)(ViewPager.java:2241)
    at android.view.View.null dispatchTouchEvent(null)(View.java:11757)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2958)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2636)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2964)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2650)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2964)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2650)
    at com.omnipotent.free.videodownloader.pro.ui.view.SwipePanel.boolean dispatchTouchEvent(android.view.MotionEvent)(SwipePanel.java:493)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2964)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2650)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2964)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2650)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2964)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2650)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2964)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2650)
    at android.view.ViewGroup.null dispatchTransformedTouchEvent(null)(ViewGroup.java:2964)
    at android.view.ViewGroup.null dispatchTouchEvent(null)(ViewGroup.java:2650)
    at com.android.internal.policy.DecorView.null superDispatchTouchEvent(null)(DecorView.java:470)
    at com.android.internal.policy.PhoneWindow.null superDispatchTouchEvent(null)(PhoneWindow.java:1828)
    at android.app.Activity.null dispatchTouchEvent(null)(Activity.java:3302)
    at androidx.appcompat.view.WindowCallbackWrapper.boolean dispatchTouchEvent(android.view.MotionEvent)(WindowCallbackWrapper.java:69)
    at androidx.appcompat.view.WindowCallbackWrapper.boolean dispatchTouchEvent(android.view.MotionEvent)(WindowCallbackWrapper.java:69)
    at com.android.internal.policy.DecorView.null dispatchTouchEvent(null)(DecorView.java:432)
    at android.view.View.null dispatchPointerEvent(null)(View.java:11996)
    at android.view.ViewRootImpl$ViewPostImeInputStage.null processPointerEvent(null)(ViewRootImpl.java:4806)
    at android.view.ViewRootImpl$ViewPostImeInputStage.null onProcess(null)(ViewRootImpl.java:4620)
    at android.view.ViewRootImpl$InputStage.null deliver(null)(ViewRootImpl.java:4158)
    at android.view.ViewRootImpl$InputStage.null onDeliverToNext(null)(ViewRootImpl.java:4211)
    at android.view.ViewRootImpl$InputStage.null forward(null)(ViewRootImpl.java:4177)
    at android.view.ViewRootImpl$AsyncInputStage.null forward(null)(ViewRootImpl.java:4304)
    at android.view.ViewRootImpl$InputStage.null apply(null)(ViewRootImpl.java:4185)
    at android.view.ViewRootImpl$AsyncInputStage.null apply(null)(ViewRootImpl.java:4361)
    at android.view.ViewRootImpl$InputStage.null deliver(null)(ViewRootImpl.java:4158)
    at android.view.ViewRootImpl$InputStage.null onDeliverToNext(null)(ViewRootImpl.java:4211)
    at android.view.ViewRootImpl$InputStage.null forward(null)(ViewRootImpl.java:4177)
    at android.view.ViewRootImpl$InputStage.null apply(null)(ViewRootImpl.java:4185)
    at android.view.ViewRootImpl$InputStage.null deliver(null)(ViewRootImpl.java:4158)
    at android.view.ViewRootImpl.null deliverInputEvent(null)(ViewRootImpl.java:6725)
    at android.view.ViewRootImpl.null doProcessInputEvents(null)(ViewRootImpl.java:6664)
    at android.view.ViewRootImpl.null enqueueInputEvent(null)(ViewRootImpl.java:6625)
    at android.view.ViewRootImpl$WindowInputEventReceiver.null onInputEvent(null)(ViewRootImpl.java:6828)
    at android.view.InputEventReceiver.null dispatchInputEvent(null)(InputEventReceiver.java:192)
    at android.os.MessageQueue.null nativePollOnce(null)(MessageQueue.java)
    at android.os.MessageQueue.null next(null)(MessageQueue.java:325)
    at android.os.Looper.null loop(null)(Looper.java:142)
    at android.app.ActivityThread.null main(null)(ActivityThread.java:6797)
    at java.lang.reflect.Method.null invoke(null)(Method.java)
    at com.android.internal.os.Zygote$MethodAndArgsCaller.null run(null)(Zygote.java:240)
    at com.android.internal.os.ZygoteInit.null main(null)(ZygoteInit.java:772)

2,我这边是把代码拷贝进工程里使用的。
3,出现在7.0 和8.0 的手机上。比较少见。

@Blankj
Copy link
Owner

Blankj commented Nov 30, 2019

既然是拷贝的,那你自己解决下吧,顺便可以给我提 PR 哈

@jhwsx
Copy link
Author

jhwsx commented Mar 6, 2020

Blankj 老师,今天看到 PhotoView 这个项目的代码时,里面提到我这个报错是还未解决的 framework 的问题,地址在 https://issuetracker.google.com/issues/36931456。PhotoView 目前是进行 try ...catch 处理的,我们也这样弄,好不好?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants