i'm getting following error , don't know why (this error rare , not reproducable me):
java.lang.nullpointerexception: attempt invoke virtual method 'void android.graphics.drawable.drawable.setbounds(int, int, int, int)' on null object reference @ android.widget.imageview.animatetransform(imageview.java:1126) @ android.transition.changeimagetransform$2.set(changeimagetransform.java:64) @ android.transition.changeimagetransform$2.set(changeimagetransform.java:61) @ android.animation.propertyvaluesholder.setanimatedvalue(propertyvaluesholder.java:938) @ android.animation.objectanimator.animatevalue(objectanimator.java:952) @ android.animation.valueanimator.animationframe(valueanimator.java:1207) @ android.animation.valueanimator.doanimationframe(valueanimator.java:1248) @ android.animation.valueanimator$animationhandler.doanimationframe(valueanimator.java:659) @ android.animation.valueanimator$animationhandler.run(valueanimator.java:682) @ android.view.choreographer$callbackrecord.run(choreographer.java:767) @ android.view.choreographer.docallbacks(choreographer.java:580) @ android.view.choreographer.doframe(choreographer.java:549) @ android.view.choreographer$framedisplayeventreceiver.run(choreographer.java:753) @ android.os.handler.handlecallback(handler.java:739) @ android.os.handler.dispatchmessage(handler.java:95) @ android.os.looper.loop(looper.java:211) @ android.app.activitythread.main(activitythread.java:5321) @ java.lang.reflect.method.invoke(native method) @ java.lang.reflect.method.invoke(method.java:372) @ com.android.internal.os.zygoteinit$methodandargscaller.run(zygoteinit.java:1016) @ com.android.internal.os.zygoteinit.main(zygoteinit.java:811) i think has android fragment , activity transitions, i'm not sure... above complete stacktrace.
maybe interesting, i'm using support-library
does have idea comes , how can prevent it?
edit
as written in comments:
- i don't know code block exception comes from
- i don't animate myself
- i assume, problem comes transactions between fragments (the animations use in app)
edit2
i did not know have make sure imageview have content. may lead above error, imageview not have image yet.
a fragment or activity transition trying animate imageview has no drawable set. ensure have drawable set imageview when animate changeimagetransform (or disable kind of animation)
Comments
Post a Comment