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

I got NoClassDefFoundError when clicking the items #11

Closed
figobbq opened this issue Jun 30, 2017 · 7 comments
Closed

I got NoClassDefFoundError when clicking the items #11

figobbq opened this issue Jun 30, 2017 · 7 comments

Comments

@figobbq
Copy link

figobbq commented Jun 30, 2017

java.lang.NoClassDefFoundError: Failed resolution of: Landroid/support/v4/animation/AnimatorCompatHelper;
at me.texy.treeview.animator.DefaultItemAnimator.resetAnimation(DefaultItemAnimator.java:520)
at me.texy.treeview.animator.DefaultItemAnimator.animateMove(DefaultItemAnimator.java:256)
at android.support.v7.widget.SimpleItemAnimator.animatePersistence(SimpleItemAnimator.java:126)
at android.support.v7.widget.RecyclerView$4.processPersistent(RecyclerView.java:504)
at android.support.v7.widget.ViewInfoStore.process(ViewInfoStore.java:241)
at android.support.v7.widget.RecyclerView.dispatchLayoutStep3(RecyclerView.java:3444)
at android.support.v7.widget.RecyclerView.dispatchLayout(RecyclerView.java:3194)
at android.support.v7.widget.RecyclerView.onLayout(RecyclerView.java:3627)

@shineM
Copy link
Owner

shineM commented Jun 30, 2017

I guess this is caused by SDK version .Plz paste your defaultConfig or you can try this : add
android {
lintOptions {
disable 'RestrictedApi'
}
}
to your app's build.gradle

@figobbq
Copy link
Author

figobbq commented Jun 30, 2017

are you Chinese?
解决了,是support v4包的版本问题,其中一个模块用了compile 'com.android.support:support-v4:+',
改成compile 'com.android.support:support-v4:25.3.1'就好了

@figobbq
Copy link
Author

figobbq commented Jun 30, 2017

另外想问一下,怎么设置每个item的长按事件?

@shineM
Copy link
Owner

shineM commented Jun 30, 2017

OK。我看你用英文我以为你是老外😂

@shineM shineM closed this as completed Jun 30, 2017
@shineM
Copy link
Owner

shineM commented Jun 30, 2017

item长按可以在bindView中 调itemView.setOnLongClickListener();

@figobbq
Copy link
Author

figobbq commented Jun 30, 2017

噢,我见你没回复,然后开了新issue

@manimaran96
Copy link

lintOptions {
disable 'RestrictedApi'
}

not worked

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

3 participants