Fragmentation icon indicating copy to clipboard operation
Fragmentation copied to clipboard

调用popTo方法后发生崩溃

Open SpannerBear opened this issue 4 years ago • 1 comments

  • Library version 1.0.6
  • androidx.fragment:fragment:1.2.5
  • code Activity.popTo(H5Fragment.class, true, null, 0);
  • Logs java.lang.IllegalStateException: Views added to a FragmentContainerView must be associated with a Fragment. View me.yokeyword.fragmentation.TransactionDelegate$16{78ce990 V.E...... ......I. 0,0-0,0} is not associated with a Fragment. at androidx.fragment.app.FragmentContainerView.addView(FragmentContainerView.java:276) at android.view.ViewGroup.addView(ViewGroup.java:4899) at android.view.ViewGroup.addView(ViewGroup.java:4872) at me.yokeyword.fragmentation.TransactionDelegate.addMockView(TransactionDelegate.java:554) at me.yokeyword.fragmentation.TransactionDelegate.mockPopToAnim(TransactionDelegate.java:454) at me.yokeyword.fragmentation.TransactionDelegate.doPopTo(TransactionDelegate.java:434) at me.yokeyword.fragmentation.TransactionDelegate.access$1100(TransactionDelegate.java:34) at me.yokeyword.fragmentation.TransactionDelegate$10.run(TransactionDelegate.java:329) at me.yokeyword.fragmentation.queue.ActionQueue.handleAction(ActionQueue.java:58) at me.yokeyword.fragmentation.queue.ActionQueue.enqueueAction(ActionQueue.java:46) at me.yokeyword.fragmentation.queue.ActionQueue.access$000(ActionQueue.java:17) at me.yokeyword.fragmentation.queue.ActionQueue$1.run(ActionQueue.java:37) at android.os.Handler.handleCallback(Handler.java:883) at android.os.Handler.dispatchMessage(Handler.java:100) at android.os.Looper.loop(Looper.java:224) at android.app.ActivityThread.main(ActivityThread.java:7520) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:539) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)

SpannerBear avatar Jul 16 '20 17:07 SpannerBear

还有个问题,请问startWithPop()不能设置startForResult()的result效果吗?它无法传requestCode呢

SpannerBear avatar Jul 17 '20 04:07 SpannerBear