diff options
author | Jim Miller <jaggies@google.com> | 2012-09-07 16:48:41 -0700 |
---|---|---|
committer | Jim Miller <jaggies@google.com> | 2012-09-07 16:48:41 -0700 |
commit | ac8f5751f52fa445af641604e476703dd5e89504 (patch) | |
tree | fa3cd8cf5126d43e18d50cabab5a404219935e15 /policy | |
parent | 4b15ab66a064ba4fae3bb1ff474d8b5fc38e5490 (diff) | |
download | frameworks_base-ac8f5751f52fa445af641604e476703dd5e89504.zip frameworks_base-ac8f5751f52fa445af641604e476703dd5e89504.tar.gz frameworks_base-ac8f5751f52fa445af641604e476703dd5e89504.tar.bz2 |
Don't hide the PIN keyboard even when a physical keyboard is present.
Originally this was done for aesthetics when we had a physical keyboard on
devices. The code also used to hide the PIN keyboard when a BT keyboard is
attached.
We now always show the keyboard, even when a physical keyboard is present.
Change-Id: I8e1f3af200071382bfe267c28d92062758ebb790
Diffstat (limited to 'policy')
-rw-r--r-- | policy/src/com/android/internal/policy/impl/keyguard/KeyguardPasswordView.java | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/policy/src/com/android/internal/policy/impl/keyguard/KeyguardPasswordView.java b/policy/src/com/android/internal/policy/impl/keyguard/KeyguardPasswordView.java index b2ce73e..7e9aa43 100644 --- a/policy/src/com/android/internal/policy/impl/keyguard/KeyguardPasswordView.java +++ b/policy/src/com/android/internal/policy/impl/keyguard/KeyguardPasswordView.java @@ -68,6 +68,9 @@ public class KeyguardPasswordView extends LinearLayout // any passwords with length less than or equal to this length. private static final int MINIMUM_PASSWORD_LENGTH_BEFORE_REPORT = 3; + // Enable this if we want to hide the on-screen PIN keyboard when a physical one is showing + private static final boolean ENABLE_HIDE_KEYBOARD = false; + public KeyguardPasswordView(Context context) { super(context); } @@ -123,10 +126,13 @@ public class KeyguardPasswordView extends LinearLayout mKeyboardHelper.setKeyboardMode(PasswordEntryKeyboardHelper.KEYBOARD_MODE_ALPHA); mKeyboardView.setVisibility(View.GONE); } else { - // Use lockscreen's numeric keyboard if the physical keyboard isn't showing mKeyboardHelper.setKeyboardMode(PasswordEntryKeyboardHelper.KEYBOARD_MODE_NUMERIC); - mKeyboardView.setVisibility(getResources().getConfiguration().hardKeyboardHidden - == Configuration.HARDKEYBOARDHIDDEN_NO ? View.INVISIBLE : View.VISIBLE); + + // Use lockscreen's numeric keyboard if the physical keyboard isn't showing + boolean hardKeyboardVisible = getResources().getConfiguration().hardKeyboardHidden + == Configuration.HARDKEYBOARDHIDDEN_NO; + mKeyboardView.setVisibility( + (ENABLE_HIDE_KEYBOARD && hardKeyboardVisible) ? View.INVISIBLE : View.VISIBLE); // The delete button is of the PIN keyboard itself in some (e.g. tablet) layouts, // not a separate view |