Android Question broadcast receiver for when running task has been changed

ArminKH

Well-Known Member
Hi
I want to create a security locker app which lock each selected programs(unlocked if correct pass entered)like most application which is available on play store
Now i have a question
We should listen for running applications and if the runing task be equal to selected package names then we should ask for password
But how is this possible?
By using service which is running always?
Or by using brodcast receiver?
If we have any receiver please let me to know
Thank u
 

ArminKH

Well-Known Member
No global intent is sent when another app starts. You can try to use the OS library to find the running apps: https://www.b4x.com/android/forum/threads/os-library.11267/#content
excuse me but i'm not sure that i understand exactly
Os library has internal service?where we could check os library for running apps?in additional service?
Can we have any sample?i want my activity starts when my special package name is running
Where we can listen for this intent?
 
Upvote 0

ArminKH

Well-Known Member
The OS library includes (partially working) methods that allow you to find the current running processes. You can use it from a service if you want.
Thank u but then our service must be always running and this is not good for batery life
And also maybe os kill that service
My goal is a way like gcm solution which has a permission in manifest and has a internal listener and if any gcm message arrived then our service starts
Now i want to do this for running apps and if running app has been changed then my service starts for check package name,etc...
This is not possible?
 
Last edited:
Upvote 0

ArminKH

Well-Known Member
THIS is my favorite locker app which has this permissions
is this using service?
Screenshot_2015-07-24-12-19-31.png
 
Last edited:
Upvote 0
Top