Always show lockdown button
Remove setting option and show lockdown button by default in the power menu Fixes: 185618694 Test: atest GlobalActionsDialogLiteTest Test: flash device, set PIN, observe button present Change-Id: I7c8f976fd73f6edf3edb26c8de31fd83eb9ac296
This commit is contained in:
@@ -9659,13 +9659,6 @@ public final class Settings {
|
||||
@Readable
|
||||
public static final String QS_AUTO_ADDED_TILES = "qs_auto_tiles";
|
||||
|
||||
/**
|
||||
* Whether the Lockdown button should be shown in the power menu.
|
||||
* @hide
|
||||
*/
|
||||
@Readable
|
||||
public static final String LOCKDOWN_IN_POWER_MENU = "lockdown_in_power_menu";
|
||||
|
||||
/**
|
||||
* Backup manager behavioral parameters.
|
||||
* This is encoded as a key=value list, separated by commas. Ex:
|
||||
|
||||
@@ -123,7 +123,6 @@ public class SecureSettings {
|
||||
Settings.Secure.SCREENSAVER_COMPONENTS,
|
||||
Settings.Secure.SCREENSAVER_ACTIVATE_ON_DOCK,
|
||||
Settings.Secure.SCREENSAVER_ACTIVATE_ON_SLEEP,
|
||||
Settings.Secure.LOCKDOWN_IN_POWER_MENU,
|
||||
Settings.Secure.SHOW_FIRST_CRASH_DIALOG_DEV_OPTION,
|
||||
Settings.Secure.VOLUME_HUSH_GESTURE,
|
||||
Settings.Secure.MANUAL_RINGER_TOGGLE_COUNT,
|
||||
|
||||
@@ -177,7 +177,6 @@ public class SecureSettingsValidators {
|
||||
VALIDATORS.put(Secure.SCREENSAVER_COMPONENTS, COMMA_SEPARATED_COMPONENT_LIST_VALIDATOR);
|
||||
VALIDATORS.put(Secure.SCREENSAVER_ACTIVATE_ON_DOCK, BOOLEAN_VALIDATOR);
|
||||
VALIDATORS.put(Secure.SCREENSAVER_ACTIVATE_ON_SLEEP, BOOLEAN_VALIDATOR);
|
||||
VALIDATORS.put(Secure.LOCKDOWN_IN_POWER_MENU, BOOLEAN_VALIDATOR);
|
||||
VALIDATORS.put(Secure.SHOW_FIRST_CRASH_DIALOG_DEV_OPTION, BOOLEAN_VALIDATOR);
|
||||
VALIDATORS.put(Secure.VOLUME_HUSH_GESTURE, NON_NEGATIVE_INTEGER_VALIDATOR);
|
||||
VALIDATORS.put(
|
||||
|
||||
@@ -2223,9 +2223,6 @@ class SettingsProtoDumpUtil {
|
||||
dumpSetting(s, p,
|
||||
Settings.Secure.LOCK_TO_APP_EXIT_LOCKED,
|
||||
SecureSettingsProto.LOCK_TO_APP_EXIT_LOCKED);
|
||||
dumpSetting(s, p,
|
||||
Settings.Secure.LOCKDOWN_IN_POWER_MENU,
|
||||
SecureSettingsProto.LOCKDOWN_IN_POWER_MENU);
|
||||
dumpSetting(s, p,
|
||||
Settings.Secure.LONG_PRESS_TIMEOUT,
|
||||
SecureSettingsProto.LONG_PRESS_TIMEOUT);
|
||||
|
||||
@@ -669,11 +669,6 @@ public class GlobalActionsDialogLite implements DialogInterface.OnDismissListene
|
||||
|
||||
int userId = user.id;
|
||||
|
||||
// No lockdown option if it's not turned on in Settings
|
||||
if (mSecureSettings.getIntForUser(Settings.Secure.LOCKDOWN_IN_POWER_MENU, 0, userId) == 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Lockdown is meaningless without a place to go.
|
||||
if (!mKeyguardStateController.isMethodSecure()) {
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user