Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 57db8bc4 authored by Jim Miller's avatar Jim Miller Committed by Android Git Automerger
Browse files

am 752ef4e0: Merge "This enables the back button in keyguard" into jb-mr1-dev

* commit '752ef4e0':
  This enables the back button in keyguard
parents d94fc289 752ef4e0
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -214,6 +214,17 @@ public class KeyguardHostView extends KeyguardViewBase {
        dialog.show();
    }

    @Override
    public boolean dispatchKeyEvent(KeyEvent event) {
        if (event.getAction() == KeyEvent.ACTION_UP
                && event.getKeyCode() == KeyEvent.KEYCODE_BACK
                && mCurrentSecuritySelection != SecurityMode.None) {
            mCallback.dismiss(false);
            return true;
        }
        return super.dispatchKeyEvent(event);
    }

    private void showTimeoutDialog() {
        int timeoutInSeconds = (int) LockPatternUtils.FAILED_ATTEMPT_TIMEOUT_MS / 1000;
        int messageId = 0;