I would like to know if it is possible to programmatically switch between different locks of the screen (i.e. lock the lock and lock the picture) in Android.
I am working on a security context based application. Depending on the context defined by the user, various screen locks are activated according to the actual context.
As I already saw, you can switch between swipe lock and unlock screen lock using:
KeyguardManager keyguardManager = (KeyguardManager)getSystemService(Activity.KEYGUARD_SERVICE); KeyguardLock lock = keyguardManager.newKeyguardLock(KEYGUARD_SERVICE); lock.reenableKeyguard(); lock.disableKeyguard();
but it would be safer if you could change between another screen lock and not turn it off. Does anyone know if different screen locks can be changed?
Thank you in!
source share