Signin/Signup with: 
Welcome, Guest
Username: Password: Remember me
Questions about Android development and PDF
  • Page:
  • 1
  • 2

TOPIC:

IllegalArgumentException occured when zoom 7 years 9 months ago #10854

  • philipp
  • philipp's Avatar
  • Offline
  • New Member
  • New Member
  • Posts: 2
  • Thank you received: 0
Are there any news on this topic? We're getting the same crash when the system destroys an activity that displays PDFViews. The Activity uses a ViewPager with a corresponding adapter to create views that are holding the PDFView instances. When the system calls onDestroy of the activity, we are doing something like ViewPager.setAdapter(null) for memory purposes. This causes the PDFView to receive an onTouchEvent that causes the crash.
Fatal Exception: java.lang.RuntimeException: Unable to destroy activity {ch.nzz.epaper/de.tdsoftware.applisher.reader.pdf.PDFReaderActivity}: java.lang.IllegalArgumentException: pointerIndex out of range
       at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:3813)
       at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:3831)
       at android.app.ActivityThread.access$1500(ActivityThread.java:175)
       at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1361)
       at android.os.Handler.dispatchMessage(Handler.java:102)
       at android.os.Looper.loop(Looper.java:146)
       at android.app.ActivityThread.main(ActivityThread.java:5602)
       at java.lang.reflect.Method.invokeNative(Method.java)
       at java.lang.reflect.Method.invoke(Method.java:515)
       at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
       at dalvik.system.NativeStart.main(NativeStart.java)
Caused by java.lang.IllegalArgumentException: pointerIndex out of range
       at android.view.MotionEvent.nativeGetAxisValue(MotionEvent.java)
       at android.view.MotionEvent.getX(MotionEvent.java:2189)
       at com.radaee.view.PDFView.motionZoom(PDFView.java:592)
       at com.radaee.view.PDFView.vTouchEvent(PDFView.java:722)

Are they any hints on this?

Thanks.

Please Log in or Create an account to join the conversation.

IllegalArgumentException occured when zoom 7 years 9 months ago #10855

  • Davide
  • Davide's Avatar
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 814
  • Thank you received: 65
Hi,
today we have published a new stable version of the library with some fixes regarding the ViewPager.
Have you checked it? Can you reproduce the issue?
www.radaeepdf.com/download/download-andr...ile/60-radaeepdf-3-7

Please Log in or Create an account to join the conversation.

IllegalArgumentException occured when zoom 7 years 9 months ago #10863

  • philipp
  • philipp's Avatar
  • Offline
  • New Member
  • New Member
  • Posts: 2
  • Thank you received: 0
Hi Davide,
thanks for the fast reply.

Can you give a short overview about the changlog entry "- FIX a ViewPager issue " of the latest lib? Does it relate to the described bug?

Please Log in or Create an account to join the conversation.

IllegalArgumentException occured when zoom 7 years 9 months ago #10866

  • Davide
  • Davide's Avatar
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 814
  • Thank you received: 65
Hi,
this thread started 7 months ago, so till now there have been a lot of changes and improvements to the ViewPager.
The latest fix was related to a strange behaviour when changing the targetSdkVersion, now we have fixed it and other minor bugs.
I suggest you to check it and let us know if it solves your problem..

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
  • 2
Powered by Kunena Forum