Android Studio shows there has 1 usage but No usages found in All places

17 Views Asked by At
  1. How did I fine the problem? the Fragment's onDestroy() was triggered multiple times, accumulated and caused crash. onDestroy() triggered multiple times

  2. What is the function ViewPager + Fragment

  3. More detail

    a) It shows there has 2 usage but I just reference once. 2 usage

    b) Then I remove the only reference. 1 usage but No usages found

  4. I tried clean & rebuild project, make cache invalid, It has no effect.

  5. I tried to remane the Fragment and all of problem disappeared(include onDestroy() was triggered multiple times), meanwhile the function can be used normally as before. rename and the problem disappeared

  6. If I still want to use the old name, I have to remove all of Fragment that FragmentManager holds.

0

There are 0 best solutions below