I have seen this question: Disable back button in android (Please do not mark as duplicate for this.)
My query is this:
I have twenty activities in a row. I want to disable the back button, so that the user can never come back to the activity he once crosses. Currently, how I do this is override onBackPressed()
and remove the super.onBackPressed()
call. This works fine.
I now need to add forty more activities, and it should have the same effect. Is there a method where I can just disable the back button for the entire application without having to code it up in each Activity?