According to the documentation System.Secure.LOCK_PATTERN_ENABLED tells you whether the autolock is enabled or not. If you set a lock pattern it will return true and if you don't set any screen lock it will return false, which is all in order.
However on the Android virtual device emulator you could set a screen lock with a pin code or password instead of a lock pattern. But if you set a pin or password LOCK_PATTERN_ENABLED will return false instead of true. Isn't this a bug? Or is there another way to find out if a screen lock is set or not (independent of it's a lock pattern, pin or password)? This seemingly wrong behaviour has also been discovered on a Motorola Milestone device with Android 2.1 installed. It let's the user set a lock pattern or password as a screen lock, however if a password is set LOCK_PATTERN_ENABLED will return false. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en