I want my app do an automatic full logout if it doesn’t use a minute.
How can I do it?
It is very simple. You can override the onPause method in activit and write a service start with a timer in it. Also redefine onStart on the rest of the service. If the minute has passed and the service is not stopped, then you need to send a message through the receiver and make a logout. If something is not clear, ask. Pro receiver Pro service
Source: https://ru.stackoverflow.com/questions/437406/
All Articles