It's given in the android docs of onOptionItemSelected that
When you successfully handle a menu item, return true. If you don't handle the menu item, you should call the superclass implementation of onOptionsItemSelected() (the default implementation returns false).
.But I don't get what the last one means. what does it mean by sayingcall the superclass implementation of onOptionItemSelected
. What does calling the superclass doAlso please do explain what
return.super.onOptionsItemSelected(item)
do?
Asked
Active
Viewed 190 times
0

Manu E Thomas
- 73
- 7
-
what do you think it does? it causes a compilation error, because there shouldn't be a . between return and super. without that point, it returns the result of the onOptionsItemSelected(item) method of it's parent class – Stultuske Apr 15 '20 at 08:41
-
Nop still can't understand what the last line means – Manu E Thomas Apr 15 '20 at 10:52