ActionBarSherlock BadParcelableException:解组时的ClassNotFoundException

时间:2013-04-05 14:29:06

标签: android actionbarsherlock android-spinner viewpagerindicator

我在我的应用中使用了ActionBarSherlock和ViewPagerIndicator的组合。我有一个活动,其中包含一个ViewPager,它使用FragmentStatePagerAdapter在标签之间滚动。其中一个片段包含一个IcsSpinner。当活动状态恢复并且我使用IcsSpinner滚动到选项卡时,我得到以下异常:

android.os.BadParcelableException: ClassNotFoundException when unmarshalling: com.actionbarsherlock.internal.widget.IcsAbsSpinner$SavedState
    at android.os.Parcel.readParcelable(Parcel.java:2077)
    at android.os.Parcel.readValue(Parcel.java:1965)
    at android.os.Parcel.readSparseArrayInternal(Parcel.java:2255)
    at android.os.Parcel.readSparseArray(Parcel.java:1687)
    at android.os.Parcel.readValue(Parcel.java:2022)
    at android.os.Parcel.readMapInternal(Parcel.java:2226)
    at android.os.Bundle.unparcel(Bundle.java:223)
    at android.os.Bundle.getSparseParcelableArray(Bundle.java:1240)
    at android.support.v4.app.FragmentManagerImpl.moveToState(Unknown Source)
    at android.support.v4.app.FragmentManagerImpl.moveToState(Unknown Source)
    at android.support.v4.app.BackStackRecord.run(Unknown Source)
    at android.support.v4.app.FragmentManagerImpl.execPendingActions(Unknown Source)
    at android.support.v4.app.FragmentManagerImpl.executePendingTransactions(Unknown Source)
    at android.support.v4.app.FragmentStatePagerAdapter.finishUpdate(Unknown Source)
    at android.support.v4.view.ViewPager.populate(Unknown Source)
    at android.support.v4.view.ViewPager.completeScroll(Unknown Source)
    at android.support.v4.view.ViewPager.computeScroll(Unknown Source)
    at android.view.View.getDisplayList(View.java:12638)
    at android.view.View.getDisplayList(View.java:12694)
    at android.view.ViewGroup.dispatchGetDisplayList(ViewGroup.java:2910)
    at android.view.View.getDisplayList(View.java:12588)
    at android.view.View.getDisplayList(View.java:12694)
    at android.view.ViewGroup.dispatchGetDisplayList(ViewGroup.java:2910)
    at android.view.View.getDisplayList(View.java:12588)
    at android.view.View.getDisplayList(View.java:12694)
    at android.view.ViewGroup.dispatchGetDisplayList(ViewGroup.java:2910)
    at android.view.View.getDisplayList(View.java:12588)
    at android.view.View.getDisplayList(View.java:12694)
    at android.view.ViewGroup.dispatchGetDisplayList(ViewGroup.java:2910)
    at android.view.View.getDisplayList(View.java:12588)
    at android.view.View.getDisplayList(View.java:12694)
    at android.view.HardwareRenderer$GlRenderer.draw(HardwareRenderer.java:1198)
    at android.view.ViewRootImpl.draw(ViewRootImpl.java:2173)
    at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:2045)
    at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1854)
    at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:989)
    at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:4351)
    at android.view.Choreographer$CallbackRecord.run(Choreographer.java:749)
    at android.view.Choreographer.doCallbacks(Choreographer.java:562)
    at android.view.Choreographer.doFrame(Choreographer.java:532)
    at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:735)
    at android.os.Handler.handleCallback(Handler.java:725)
    at android.os.Handler.dispatchMessage(Handler.java:92)
    at android.os.Looper.loop(Looper.java:137)
    at android.app.ActivityThread.main(ActivityThread.java:5041)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:511)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
    at dalvik.system.NativeStart.main(Native Method)

知道可能导致这种情况的原因吗?

由于 大卫

0 个答案:

没有答案