I have 3 Fragments
A, B, and C. The fragment in B contain a Recyclerview
(list of items), and I have a link from A-to->B and from C-to->B, which means I can reach the fragment B from both destinations A and C. (A)-->B<--(C). What do I want, if I came from A->B and I clicked on an item in the list I will have action different from the action if I came from C->B.
Asked
Active
Viewed 53 times
0

labed AbdelJalil
- 15
- 1
- 7
-
identify in B parent fragment instance A or C and take actions, for more on instance of more https://stackoverflow.com/questions/7313559/what-is-the-instanceof-operator-used-for-in-java – Jaydeep Devda Aug 19 '21 at 04:14
-
how you are using click callback with interface or direct into recyclerView – Amit pandey Aug 19 '21 at 04:31
-
I'm using CallBack with interface – labed AbdelJalil Aug 19 '21 at 04:33