I'm implementing the onBackPressed() method in my activity. It's crucial to my app that I have this functionality. But, the control never enters this function. It enters onPause() instead, when I press the back button.
But the problem is I can't have the same logic in onPause() because when I call another activity, the current activity calls onPause() and I don't want it to execute what should be in onBackPressed().
Please help.
public void onBackPresed(){
Log.d(TAG,"inside onBackPressed()");
if(STATE == PREVIEW){
}
}
public void onBackPresed(){
you typed one 's', it should be onBackPressed()
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With