Identify if the app is in the background or just switched from Activity

Asked

Viewed 29 times

1

Is there any way to determine if the app was for background or just if it switched from Activity?

  • I do not master much android, but I believe you need to create a service for this, because of the life cycle of activities, only for them I believe it is not possible.

  • but how to make this service know that the app is in the background or just switched to another app?

  • thanks for the indication, had not seen this question

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.