-
Notifications
You must be signed in to change notification settings - Fork 29
Description
First of all thank you for your good work on this library.
When I add animation, to a content of views like this:
In onCreateView() of my Fragment, using ButterKnife.bind(this, view);
itisfListLayout.setInAnimator(new PropertyIn(View.TRANSLATION_Y, itisfRootLayout.getHeight(), 0).setDuration(500));
itisfListLayout.setOutAnimator(new PropertyOut(View.TRANSLATION_Y, 0, -itisfRootLayout.getHeight()).setDuration(500));
itisfListLayout.setLocationType(CannyViewAnimator.IN_ALWAYS_TOP);
itisfListLayout.setAnimateType(CannyViewAnimator.TOGETHER);
itisfListLayout.setDisplayedChildIndex(itisfListLayout.getDisplayedChildIndex() + 1);
The animation works well, but when I rotate de device NullPointerException error appears:
Caused by: java.lang.NullPointerException
at com.livetyping.library.CannyViewAnimator.changeVisibility(CannyViewAnimator.java:114)
at com.livetyping.library.ViewAnimator.setDisplayedChildIndex(ViewAnimator.java:37)
at com.livetyping.library.ViewAnimator.onRestoreInstanceState(ViewAnimator.java:170)
at android.view.View.dispatchRestoreInstanceState(View.java:12284)
at android.view.ViewGroup.dispatchRestoreInstanceState(ViewGroup.java:2620)
at android.view.ViewGroup.dispatchRestoreInstanceState(ViewGroup.java:2626)
at android.view.View.restoreHierarchyState(View.java:12262)
Any idea how is this happening?
Thank you.