Here is an extension to get the activity lifecycle state of an app. So e.g. whether an app is switched in the background and / or in idle (sleep) mode. I added now a move app to background method. So the extension might now also be helpful on Kodular.