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

Commit 7f06eed7 authored by Adrian Roos's avatar Adrian Roos
Browse files

DPM control for remote input when locked

Bug: 26981262
Change-Id: I84f26ebe807e89fd56ffc3bbc7fc20f12e2f7391
parent f7a2afb4
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -6066,6 +6066,7 @@ package android.app.admin {
    field public static final int KEYGUARD_DISABLE_FEATURES_ALL = 2147483647; // 0x7fffffff
    field public static final int KEYGUARD_DISABLE_FEATURES_NONE = 0; // 0x0
    field public static final int KEYGUARD_DISABLE_FINGERPRINT = 32; // 0x20
    field public static final int KEYGUARD_DISABLE_REMOTE_INPUT = 64; // 0x40
    field public static final int KEYGUARD_DISABLE_SECURE_CAMERA = 2; // 0x2
    field public static final int KEYGUARD_DISABLE_SECURE_NOTIFICATIONS = 4; // 0x4
    field public static final int KEYGUARD_DISABLE_TRUST_AGENTS = 16; // 0x10
+1 −0
Original line number Diff line number Diff line
@@ -6233,6 +6233,7 @@ package android.app.admin {
    field public static final int KEYGUARD_DISABLE_FEATURES_ALL = 2147483647; // 0x7fffffff
    field public static final int KEYGUARD_DISABLE_FEATURES_NONE = 0; // 0x0
    field public static final int KEYGUARD_DISABLE_FINGERPRINT = 32; // 0x20
    field public static final int KEYGUARD_DISABLE_REMOTE_INPUT = 64; // 0x40
    field public static final int KEYGUARD_DISABLE_SECURE_CAMERA = 2; // 0x2
    field public static final int KEYGUARD_DISABLE_SECURE_NOTIFICATIONS = 4; // 0x4
    field public static final int KEYGUARD_DISABLE_TRUST_AGENTS = 16; // 0x10
+1 −0
Original line number Diff line number Diff line
@@ -6071,6 +6071,7 @@ package android.app.admin {
    field public static final int KEYGUARD_DISABLE_FEATURES_ALL = 2147483647; // 0x7fffffff
    field public static final int KEYGUARD_DISABLE_FEATURES_NONE = 0; // 0x0
    field public static final int KEYGUARD_DISABLE_FINGERPRINT = 32; // 0x20
    field public static final int KEYGUARD_DISABLE_REMOTE_INPUT = 64; // 0x40
    field public static final int KEYGUARD_DISABLE_SECURE_CAMERA = 2; // 0x2
    field public static final int KEYGUARD_DISABLE_SECURE_NOTIFICATIONS = 4; // 0x4
    field public static final int KEYGUARD_DISABLE_TRUST_AGENTS = 16; // 0x10
+5 −0
Original line number Diff line number Diff line
@@ -2570,6 +2570,11 @@ public class DevicePolicyManager {
     */
    public static final int KEYGUARD_DISABLE_FINGERPRINT = 1 << 5;

    /**
     * Disable text entry into notifications on secure keyguard screens (e.g. PIN/Pattern/Password).
     */
    public static final int KEYGUARD_DISABLE_REMOTE_INPUT = 1 << 6;

    /**
     * Disable all current and future keyguard customizations.
     */
+4 −1
Original line number Diff line number Diff line
@@ -2246,9 +2246,12 @@ public abstract class BaseStatusBar extends SystemUI implements
                Settings.Secure.LOCK_SCREEN_ALLOW_REMOTE_INPUT,
                0,
                mCurrentUserId) != 0;
        final boolean remoteInputDpm = (dpmFlags
                & DevicePolicyManager.KEYGUARD_DISABLE_REMOTE_INPUT) == 0;


        setShowLockscreenNotifications(show && allowedByDpm);
        setLockScreenAllowRemoteInput(remoteInput);
        setLockScreenAllowRemoteInput(remoteInput && remoteInputDpm);
    }

    protected abstract void setAreThereNotifications();