File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
policy/src/com/android/internal/policy/impl Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -114,6 +114,10 @@ public class LockPatternKeyguardView extends KeyguardViewBase implements Handler
114114 private final int MSG_SHOW_FACELOCK_AREA_VIEW = 0 ;
115115 private final int MSG_HIDE_FACELOCK_AREA_VIEW = 1 ;
116116
117+ // Long enough to stay black while dialer comes up
118+ // Short enough to not be black if the user goes back immediately
119+ private final int FACELOCK_VIEW_AREA_EMERGENCY_HIDE_TIMEOUT = 1000 ;
120+
117121 /**
118122 * The current {@link KeyguardScreen} will use this to communicate back to us.
119123 */
@@ -311,6 +315,13 @@ public void recreateMe(Configuration config) {
311315 }
312316
313317 public void takeEmergencyCallAction () {
318+ // FaceLock must be stopped if it is running when emergency call is pressed
319+ stopAndUnbindFromFaceLock ();
320+
321+ // Delay hiding FaceLock area so unlock doesn't display while dialer is coming up
322+ mHandler .sendEmptyMessageDelayed (MSG_HIDE_FACELOCK_AREA_VIEW ,
323+ FACELOCK_VIEW_AREA_EMERGENCY_HIDE_TIMEOUT );
324+
314325 pokeWakelock (EMERGENCY_CALL_TIMEOUT );
315326 if (TelephonyManager .getDefault ().getCallState ()
316327 == TelephonyManager .CALL_STATE_OFFHOOK ) {
You can’t perform that action at this time.
0 commit comments