mirror of
https://github.com/Divested-Mobile/DivestOS-Build.git
synced 2024-09-06 17:42:25 +00:00
55 lines
3.2 KiB
Diff
55 lines
3.2 KiB
Diff
From c46d22ad7a92e72f4ba9ba3a36e8dbdb566f4a07 Mon Sep 17 00:00:00 2001
|
|
From: Tad <tad@spotco.us>
|
|
Date: Sun, 18 Dec 2016 09:36:07 -0500
|
|
Subject: [PATCH] Hide passwords by default
|
|
|
|
Change-Id: I95e26ff6219f6209d5b9fc7ae92a453b53b0aa76
|
|
---
|
|
core/java/android/text/method/TextKeyListener.java | 2 +-
|
|
core/java/com/android/internal/widget/PasswordEntryKeyboardHelper.java | 2 +-
|
|
packages/Keyguard/src/com/android/keyguard/PasswordTextView.java | 2 +-
|
|
3 files changed, 3 insertions(+), 3 deletions(-)
|
|
|
|
diff --git a/core/java/android/text/method/TextKeyListener.java b/core/java/android/text/method/TextKeyListener.java
|
|
index 994f3d7..b2ac244 100644
|
|
--- a/core/java/android/text/method/TextKeyListener.java
|
|
+++ b/core/java/android/text/method/TextKeyListener.java
|
|
@@ -291,7 +291,7 @@ public class TextKeyListener extends BaseKeyListener implements SpanWatcher {
|
|
boolean cap = System.getInt(resolver, System.TEXT_AUTO_CAPS, 1) > 0;
|
|
boolean text = System.getInt(resolver, System.TEXT_AUTO_REPLACE, 1) > 0;
|
|
boolean period = System.getInt(resolver, System.TEXT_AUTO_PUNCTUATE, 1) > 0;
|
|
- boolean pw = System.getInt(resolver, System.TEXT_SHOW_PASSWORD, 1) > 0;
|
|
+ boolean pw = System.getInt(resolver, System.TEXT_SHOW_PASSWORD, 0) > 0;
|
|
|
|
mPrefs = (cap ? AUTO_CAP : 0) |
|
|
(text ? AUTO_TEXT : 0) |
|
|
diff --git a/core/java/com/android/internal/widget/PasswordEntryKeyboardHelper.java b/core/java/com/android/internal/widget/PasswordEntryKeyboardHelper.java
|
|
index b2c9dc5..dc5b7f9 100644
|
|
--- a/core/java/com/android/internal/widget/PasswordEntryKeyboardHelper.java
|
|
+++ b/core/java/com/android/internal/widget/PasswordEntryKeyboardHelper.java
|
|
@@ -159,7 +159,7 @@ public class PasswordEntryKeyboardHelper implements OnKeyboardActionListener {
|
|
mKeyboardState = KEYBOARD_STATE_NORMAL;
|
|
final boolean visiblePassword = Settings.System.getInt(
|
|
mContext.getContentResolver(),
|
|
- Settings.System.TEXT_SHOW_PASSWORD, 1) != 0;
|
|
+ Settings.System.TEXT_SHOW_PASSWORD, 0) != 0;
|
|
final boolean enablePreview = false; // TODO: grab from configuration
|
|
mKeyboardView.setPreviewEnabled(visiblePassword && enablePreview);
|
|
break;
|
|
diff --git a/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java b/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java
|
|
index 48737f9..3f4c381 100644
|
|
--- a/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java
|
|
+++ b/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java
|
|
@@ -134,7 +134,7 @@ public class PasswordTextView extends View {
|
|
mDrawPaint.setColor(0xffffffff);
|
|
mDrawPaint.setTypeface(Typeface.create("sans-serif-light", 0));
|
|
mShowPassword = Settings.System.getInt(mContext.getContentResolver(),
|
|
- Settings.System.TEXT_SHOW_PASSWORD, 1) == 1;
|
|
+ Settings.System.TEXT_SHOW_PASSWORD, 0) == 1;
|
|
mAppearInterpolator = AnimationUtils.loadInterpolator(mContext,
|
|
android.R.interpolator.linear_out_slow_in);
|
|
mDisappearInterpolator = AnimationUtils.loadInterpolator(mContext,
|
|
--
|
|
2.9.3
|
|
|