lucasr/twoway-view

void org.lucasr.twowayview.widget.ItemEntries.setAdapterSize(int)

kimzz opened this issue · 1 comments

kimzz commented

I'm getting NullPointerException as below error when I resume fragment

.../... E/AndroidRuntime: FATAL EXCEPTION: main
        Process: com.kabinet, PID: 14182
        java.lang.NullPointerException: Attempt to invoke virtual method 'void org.lucasr.twowayview.widget.ItemEntries.setAdapterSize(int)' on a null object reference
        at org.lucasr.twowayview.widget.BaseLayoutManager.onLayoutChildren(BaseLayoutManager.java:355)
        at android.support.v7.widget.RecyclerView.dispatchLayoutStep2(RecyclerView.java:3028)
        at android.support.v7.widget.RecyclerView.dispatchLayout(RecyclerView.java:2906)
        at android.support.v7.widget.RecyclerView.onLayout(RecyclerView.java:3283)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1702)
        at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1556)
        at android.widget.LinearLayout.onLayout(LinearLayout.java:1465)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.widget.FrameLayout.layoutChildren(FrameLayout.java:573)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:508)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1077)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.support.v4.widget.DrawerLayout.onLayout(DrawerLayout.java:1187)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.widget.FrameLayout.layoutChildren(FrameLayout.java:573)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:508)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.support.v7.widget.ActionBarOverlayLayout.onLayout(ActionBarOverlayLayout.java:435)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.widget.FrameLayout.layoutChildren(FrameLayout.java:573)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:508)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1702)
        at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1556)
        at android.widget.LinearLayout.onLayout(LinearLayout.java:1465)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.widget.FrameLayout.layoutChildren(FrameLayout.java:573)
        at android.widget.FrameLayout.onLayout(FrameLayout.java:508)
        at android.view.View.layout(View.java:16761)
        at android.view.ViewGroup.layout(ViewGroup.java:5333)
        at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2381)
        at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2090)
        at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1239)
        at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6752)
        at android.view.Choreographer$CallbackRecord.run(Choreographer.java:777)
        at android.view.Choreographer.doCallbacks(Choreographer.java:590)
        at android.view.Choreographer.doFrame(Choreographer.java:560)
        at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:763)
        at android.os.Handler.handleCallback(Handler.java:739)
        at android.os.Handler.dispatchMessage(Handler.java:95)
        at android.os.Looper.loop(Looper.java:145)
        at android.app.ActivityThread.main(ActivityThread.java:6145)
        at java.lang.reflect.Method.invoke(Native Method)
        at java.lang.reflect.Method.invoke(Method.java:372)
        at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)

Same problem