OneActivity -> TabLayout - > FragmentA, FragmentB, FragmentC
TwoActivity -> some clickable widgets
From FragmentA I will go to TwoActivity ang again from TwoActivity to another instance of TwoActivity and again from TwoActivity to another instance of TwoActivity and if some action happens in these TwoActivity I want to have that action value in FragmentC of OneActivity if user navigate to FragmentC.
I tried eventbus but not found solution for it. I want to know the best design pattern for this purpose.
you can use
startActivityForResult
andoverride
the methodonActivityResult
in theOneActivity
to handle the result returned fromTwoActivity
and forward the result toFragmentC
in your own method. Another way you can useObservers
andObservable
here