Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4456a999 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Update DPM.setKeyguardDisabled to also dismiss the keyguard"

parents 6307647e 32a3bf35
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -6784,6 +6784,7 @@ public class DevicePolicyManager {
        return null;
    }

    // STOPSHIP: Remove reference to CUR_DEVELOPMENT before shipping
    /**
     * Called by a device owner to disable the keyguard altogether.
     * <p>
@@ -6792,6 +6793,10 @@ public class DevicePolicyManager {
     * password, pin or pattern is set after the keyguard was disabled, the keyguard stops being
     * disabled.
     *
     * <p>
     * As of {@link android.os.Build.VERSION_CODES#CUR_DEVELOPMENT}, this call also dismisses the
     * keyguard if it is currently shown.
     *
     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
     * @param disabled {@code true} disables the keyguard, {@code false} reenables it.
     * @return {@code false} if attempting to disable the keyguard while a lock password was in
+3 −0
Original line number Diff line number Diff line
@@ -9085,6 +9085,9 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
                return false;
            }
            mLockPatternUtils.setLockScreenDisabled(disabled, userId);
            mInjector.getIWindowManager().dismissKeyguard(null);
        } catch (RemoteException e) {
            // Same process, does not happen.
        } finally {
            mInjector.binderRestoreCallingIdentity(ident);
        }