From c384940f06bec2ea6bb9ae0fa78e39bda621d2de Mon Sep 17 00:00:00 2001 From: Michael Bestas Date: Thu, 12 Dec 2013 05:40:54 +0200 Subject: [PATCH] Settings: Forward port lock pattern grid size (2/2) Fingerprint: Forward challenge extras The forward port of custom pattern sizes introduced a bug that would cause an NPE when trying to add a fingerprint for security. This patch forwards the extras associated with the challenge that would have normally been passed directly in to the ChooseLockPattern fragment. TICKET: CYNGNOS-1490 Settings: forward decrypt required on boot flag This wasn't being pass forward and all of the defaults had it set to true. Ticket: CYNGNOS-2270 Signed-off-by: Roman Birg Settings: allow rotation while setting new pattern Signed-off-by: Roman Birg Settings: use the actual user id to set pattern size Ticket: CYNGNOS-2462 Settings: handle decrypting larger pattern sizes Signed-off-by: Roman Birg CryptKeeper: pattern unlock displays incorrect pw when correct fakeUnlockAttempt() gets called when the user inputs any pattern length < 4 which queues up the 'incorrect error' message. The message needs to be cleared before trying to actually check the password so it never goes through in case the password was correct. Signed-off-by: Roman Birg Settings: fix non lock pattern CryptKeeper crash Signed-off-by: Roman Birg CryptKeeper: layout whole screen in bounds Add flags to make the screen layout properly on devices with the navigation bar visible Signed-off-by: Roman Birg CryptKeeper improvements - Status text was used enough to warrant it being a field variable instead of looking for the view every time - Display proper text after changing pattern sizes (to input a pattern, not a password) - Disable changing pattern sizes while validaing pattern REFS: LETTUCE-557, LETTUCE-352 Signed-off-by: Roman Birg Settings: Use GLIF Theme for missing Settings > Screen lock Activities Icons by Asher Change-Id: Icf1627b41ef604302a5819ad3b1bdfd6d8479202 Change-Id: I7078d703c218cd096d9b77c003a94b52fbce6322 --- AndroidManifest.xml | 4 + res/drawable/ic_security_pattern_3x3.xml | 26 +++ res/drawable/ic_security_pattern_4x4.xml | 26 +++ res/drawable/ic_security_pattern_5x5.xml | 26 +++ res/drawable/ic_security_pattern_6x6.xml | 26 +++ .../crypt_keeper_pattern_entry.xml | 11 ++ .../choose_lock_pattern_size_header.xml | 25 +++ res/layout/crypt_keeper_pattern_entry.xml | 12 ++ res/layout/crypt_keeper_pattern_sizes.xml | 69 ++++++++ res/values/cm_strings.xml | 11 ++ res/values/lineage_styles.xml | 23 +++ res/xml/security_settings_pattern_size.xml | 44 +++++ src/com/android/settings/CryptKeeper.java | 95 ++++++++--- .../settings/password/ChooseLockPattern.java | 42 +++-- .../password/ChooseLockPatternSize.java | 159 ++++++++++++++++++ .../settings/password/ConfirmLockPattern.java | 5 +- 16 files changed, 571 insertions(+), 33 deletions(-) create mode 100644 res/drawable/ic_security_pattern_3x3.xml create mode 100644 res/drawable/ic_security_pattern_4x4.xml create mode 100644 res/drawable/ic_security_pattern_5x5.xml create mode 100644 res/drawable/ic_security_pattern_6x6.xml create mode 100644 res/layout/choose_lock_pattern_size_header.xml create mode 100644 res/layout/crypt_keeper_pattern_sizes.xml create mode 100644 res/values/lineage_styles.xml create mode 100644 res/xml/security_settings_pattern_size.xml create mode 100644 src/com/android/settings/password/ChooseLockPatternSize.java diff --git a/AndroidManifest.xml b/AndroidManifest.xml index 54f0dc9a0cb..25a70363e80 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -1784,6 +1784,10 @@ android:label="@string/lockpassword_choose_lock_generic_header" android:excludeFromRecents="true" /> + + diff --git a/res/drawable/ic_security_pattern_3x3.xml b/res/drawable/ic_security_pattern_3x3.xml new file mode 100644 index 00000000000..b8e4df44a0f --- /dev/null +++ b/res/drawable/ic_security_pattern_3x3.xml @@ -0,0 +1,26 @@ + + + + diff --git a/res/drawable/ic_security_pattern_4x4.xml b/res/drawable/ic_security_pattern_4x4.xml new file mode 100644 index 00000000000..92c580f5e2c --- /dev/null +++ b/res/drawable/ic_security_pattern_4x4.xml @@ -0,0 +1,26 @@ + + + + diff --git a/res/drawable/ic_security_pattern_5x5.xml b/res/drawable/ic_security_pattern_5x5.xml new file mode 100644 index 00000000000..7b4dabaad79 --- /dev/null +++ b/res/drawable/ic_security_pattern_5x5.xml @@ -0,0 +1,26 @@ + + + + diff --git a/res/drawable/ic_security_pattern_6x6.xml b/res/drawable/ic_security_pattern_6x6.xml new file mode 100644 index 00000000000..1861284dbbf --- /dev/null +++ b/res/drawable/ic_security_pattern_6x6.xml @@ -0,0 +1,26 @@ + + + + diff --git a/res/layout-sw600dp/crypt_keeper_pattern_entry.xml b/res/layout-sw600dp/crypt_keeper_pattern_entry.xml index 393700870cc..b83f5e26f3d 100644 --- a/res/layout-sw600dp/crypt_keeper_pattern_entry.xml +++ b/res/layout-sw600dp/crypt_keeper_pattern_entry.xml @@ -36,6 +36,17 @@ + + + + + + diff --git a/res/layout/choose_lock_pattern_size_header.xml b/res/layout/choose_lock_pattern_size_header.xml new file mode 100644 index 00000000000..a3a102bf042 --- /dev/null +++ b/res/layout/choose_lock_pattern_size_header.xml @@ -0,0 +1,25 @@ + + + + diff --git a/res/layout/crypt_keeper_pattern_entry.xml b/res/layout/crypt_keeper_pattern_entry.xml index 00d3d6ecd55..b2172a43f79 100644 --- a/res/layout/crypt_keeper_pattern_entry.xml +++ b/res/layout/crypt_keeper_pattern_entry.xml @@ -36,6 +36,18 @@ + + + + + + diff --git a/res/layout/crypt_keeper_pattern_sizes.xml b/res/layout/crypt_keeper_pattern_sizes.xml new file mode 100644 index 00000000000..020b6888e8e --- /dev/null +++ b/res/layout/crypt_keeper_pattern_sizes.xml @@ -0,0 +1,69 @@ + + + + +