I have an activity where I am calling three fragments - each depending on each other:
A(ctivity) -> f1 (Fragment one, title {is|should}: list) -> f2 (Fragment two,
I use following workaround:
1) set 1st fragment setHasOptionsMenu(false) before add 2nd fragment on top of 1st one.
2) set 1st fragment setHasOptionsMenu(true) in onOptionsItemSelected() after return from 2nd fragment.
3) onCreateOptionsMenu() of 1st fragment should be called and you can change actionbar here.
But I want to know a better solution.