I created a button, now i want that if I click on it, my app does a pause till I click again then it should resume at the same point. I've tried to use onPause() but it hasn't any effect for my app.
@Override
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
if (isChecked) {
Method should be paused!
} else {
Method should be resumed!
}
}
I've a method which has an TTS and an timecounter. Now i want to add a pause/resume button. I have no idea how I can handle it.