Show DialogFragment from another DialogFragment

前端 未结 9 732
春和景丽
春和景丽 2021-02-05 10:33

I have a DialogFragment that displays a list of options to the user, one of these options is \"Delete\" option, when the user presses the delete option I want to sh

9条回答
  •  迷失自我
    2021-02-05 11:02

    I got the exact same problem, this situation does not happen when you try to open a DialogFragment from a Fragment.

    The only solution I found was to modify the following call:

    fragment.show(ft, fragmentTag);
    

    To:

    fragment.show(getFragmentManager(), fragmentTag);
    

    The problem with this solution is that we cannot work on the FragmentTransition.

    I don't understand why the behavior is different than with the fragments.

提交回复
热议问题