gpt4 book ai didi

android - NoClassDefFoundError : android. support.v7.widget.helper.ItemTouchHelper$3

转载 作者:行者123 更新时间:2023-12-05 00:21:35 26 4
gpt4 key购买 nike

嗨,我想在 RecyclerView 上创建滑动删除结果是崩溃:

build.gradle ,我导入了所有需要的库。在代码中我可以使用 ItemTouchHelper上课,但是当我想刷一个项目时它崩溃了。
build.gradle

compile 'com.android.support:appcompat-v7:25.0.0'
compile 'com.android.support:recyclerview-v7:25.0.0'
compile 'com.android.support:cardview-v7:25.0.0'
compile 'com.android.support.constraint:constraint-layout:1.0.0-beta4'
compile 'com.android.support:support-v13:25.0.0'
compile 'com.android.support:design:25.0.0'

碰撞:

FATAL EXCEPTION: main java.lang.NoClassDefFoundError: android.support.v7.widget.helper.ItemTouchHelper$3 at android.support.v7.widget.helper.ItemTouchHelper.select(ItemTouchHelper.java:608) at android.support.v7.widget.helper.ItemTouchHelper$2.onTouchEvent(ItemTouchHelper.java:389) at android.support.v7.widget.RecyclerView.dispatchOnItemTouch(RecyclerView.java:2519) at android.support.v7.widget.RecyclerView.onTouchEvent(RecyclerView.java:2662) at android.view.View.dispatchTouchEvent(View.java:9300) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2547) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2240) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2553) at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2254) at com.android.internal.policy.PhoneWindow$DecorView.superDispatchTouchEvent(PhoneWindow.java:2403) at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent(PhoneWindow.java:1737) at android.app.Activity.dispatchTouchEvent(Activity.java:2771) at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:67) at android.support.v7.view.WindowCallbackWrapper.dispatchTouchEvent(WindowCallbackWrapper.java:67) at com.android.internal.policy.PhoneWindow$DecorView.dispatchTouchEvent(PhoneWindow.java:2364) at android.view.View.dispatchPointerEvent(View.java:9520) at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4230) at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4096) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3642) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3695) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3661) at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:3787) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3669) at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:3844) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3642) at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:3695) at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:3661) at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:3669) at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:3642) at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:5922) at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:5896) at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:5857) at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewR

最佳答案

前几天遇到这个问题。
在我的情况下,它是由 修复的。全部更新 com.android.support:*从 25.3.1 到 的依赖关系26.0.0 .并确保他们都使用相同的版本。
希望它会帮助某人。

关于android - NoClassDefFoundError : android. support.v7.widget.helper.ItemTouchHelper$3,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45098895/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com