My fragment replaces the parent Activity options with a specific option item but when I click on the item, only activity\'s onOptionItemSelected
gets called eventho
I agree with the currently accepted solution, but another possible cause is having an ambiguous class reference. I had a custom class in my project named MenuItem and my Fragment was interpreting that custom.MenuItem as the parameter type instead of android.view.MenuItem
The symptoms were a wiggly red underline on my Override and IDE message indicating that onOptionsItemSelected will not be called.