summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Colonna <bcolonna@google.com>2011-10-13 18:19:30 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-10-13 18:19:30 -0700
commit3505abf31df8dafab2c83ceb8f85b5694cac3b78 (patch)
tree5675080c9ebbd3877572170521bea0f404daeb2e
parent8a058cbf12c590db810fe8d9fab6f4f614909329 (diff)
parent9eeaaa39c3bad72a369aeff11f95ffea13a5e214 (diff)
downloadframeworks_base-3505abf31df8dafab2c83ceb8f85b5694cac3b78.zip
frameworks_base-3505abf31df8dafab2c83ceb8f85b5694cac3b78.tar.gz
frameworks_base-3505abf31df8dafab2c83ceb8f85b5694cac3b78.tar.bz2
Merge "Fix 5451144: Poking wakelock upon fallback" into ics-mr0
-rw-r--r--policy/src/com/android/internal/policy/impl/LockPatternKeyguardView.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/policy/src/com/android/internal/policy/impl/LockPatternKeyguardView.java b/policy/src/com/android/internal/policy/impl/LockPatternKeyguardView.java
index d1bb8d1..c3f6767 100644
--- a/policy/src/com/android/internal/policy/impl/LockPatternKeyguardView.java
+++ b/policy/src/com/android/internal/policy/impl/LockPatternKeyguardView.java
@@ -126,6 +126,9 @@ public class LockPatternKeyguardView extends KeyguardViewBase implements Handler
// The service can take a couple of seconds to start on the first try after boot
private final int FACELOCK_VIEW_AREA_SERVICE_TIMEOUT = 3000;
+ // So the user has a consistent amount of time when brought to the backup method from FaceLock
+ private final int BACKUP_LOCK_TIMEOUT = 5000;
+
/**
* The current {@link KeyguardScreen} will use this to communicate back to us.
*/
@@ -587,6 +590,10 @@ public class LockPatternKeyguardView extends KeyguardViewBase implements Handler
if (mLockPatternUtils.usingBiometricWeak() &&
mLockPatternUtils.isBiometricWeakInstalled()) {
+ // Note that show() gets called before the screen turns off to set it up for next time
+ // it is turned on. We don't want to set a timeout on the FaceLock area here because it
+ // may be gone by the time the screen is turned on again. We set the timout when the
+ // screen turns on instead.
showFaceLockArea();
} else {
hideFaceLockArea();
@@ -1252,6 +1259,7 @@ public class LockPatternKeyguardView extends KeyguardViewBase implements Handler
if (DEBUG) Log.d(TAG, "FaceLock cancel()");
hideFaceLockArea(); // Expose fallback
stopFaceLock();
+ mKeyguardScreenCallback.pokeWakelock(BACKUP_LOCK_TIMEOUT);
}
// Allows the Face Unlock service to poke the wake lock to keep the lockscreen alive