LockPatternUtils: isSecure: respect profile settings

When the lock screen is set to secure and overridden to insecure
by profile settings, isSecure() would return true causing confusion
to some code.

For example, attempting to use a lockscreen shortcut
to launch an activity will cause the device to soft-reboot due to
recursive calling and a stack overflow.

Change-Id: I02984671c2a047765f4da1f6a44bb19dea5bf2d3

Conflicts:

	core/java/com/android/internal/widget/LockPatternUtils.java
Framework: Fix Profiles Insecure lock screen not working (take 2)

Change-Id: I16744dc6523787dbe011a9a0a8d61b0702b62344

Signed-off-by: igio90 <giovanni.rocca.90@gmail.com>
Framework: Forward port Fix Profiles Insecure lock screen not working

This fixes Issue 6226: The insecure lockscreen setting is not being activated with
the use of profiles if the default is secure (PIN or Password)

Change-Id: Iaba6d39df0000da073c3ea0c35de1c78f63ad08d

Signed-off-by: igio90 <giovanni.rocca.90@gmail.com>