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

androidx 适配问题 #29

Open
shenyongwang opened this issue May 13, 2020 · 1 comment
Open

androidx 适配问题 #29

shenyongwang opened this issue May 13, 2020 · 1 comment

Comments

@shenyongwang
Copy link

Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean androidx.fragment.app.FragmentManagerImpl.isDestroyed()' on a null object reference
at androidx.fragment.app.Fragment.performDetach(Fragment.java:2849)
at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:1034)
at androidx.fragment.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManagerImpl.java:1238)
at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:1303)
at androidx.fragment.app.FragmentManagerImpl.dispatchStateChange(FragmentManagerImpl.java:2659)
at androidx.fragment.app.FragmentManagerImpl.dispatchDestroy(FragmentManagerImpl.java:2644)
at androidx.fragment.app.FragmentController.dispatchDestroy(FragmentController.java:329)
at androidx.fragment.app.FragmentActivity.onDestroy(FragmentActivity.java:366)
at androidx.appcompat.app.AppCompatActivity.onDestroy(AppCompatActivity.java:242)
at com.ess.filepicker.activity.SelectFileByScanActivity.onDestroy(SelectFileByScanActivity.java:122)
at android.app.Activity.performDestroy(Activity.java:7266)
at android.app.Instrumentation.callActivityOnDestroy(Instrumentation.java:1316)
at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:4767)
大佬 androidx 报上面的bug,望解决 万分感谢

@roomanl
Copy link

roomanl commented Jul 4, 2020

我改成androidx也出现这个问题了。BaseFileFragment文件onDetach方法里面childFragmentManager.set(this, null);注释即可解决

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

2 participants