• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2008 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package com.android.internal.policy.impl;
18 
19 /**
20  * Within a keyguard, there may be several screens that need a callback
21  * to the host keyguard view.
22  */
23 public interface KeyguardScreenCallback extends KeyguardViewCallback {
24 
25     /**
26      * Transition to the lock screen.
27      */
goToLockScreen()28     void goToLockScreen();
29 
30     /**
31      * Transition to the unlock screen.
32      */
goToUnlockScreen()33     void goToUnlockScreen();
34 
35     /**
36      * The user reported that they forgot their pattern (or not, when they want to back out of the
37      * forgot pattern screen).
38      *
39      * @param isForgotten True if the user hit the forgot pattern, false if they want to back out
40      *        of the account screen.
41      */
forgotPattern(boolean isForgotten)42     void forgotPattern(boolean isForgotten);
43 
44     /**
45      * @return Whether the keyguard requires some sort of PIN.
46      */
isSecure()47     boolean isSecure();
48 
49     /**
50      * @return Whether we are in a mode where we only want to verify the
51      *   user can get past the keyguard.
52      */
isVerifyUnlockOnly()53     boolean isVerifyUnlockOnly();
54 
55     /**
56      * Stay on me, but recreate me (so I can use a different layout).
57      */
recreateMe()58     void recreateMe();
59 
60     /**
61      * Take action to send an emergency call.
62      */
takeEmergencyCallAction()63     void takeEmergencyCallAction();
64 
65     /**
66      * Report that the user had a failed attempt unlocking via the pattern.
67      */
reportFailedPatternAttempt()68     void reportFailedPatternAttempt();
69 
70     /**
71      * Report whether we there's another way to unlock the device.
72      * @return true
73      */
doesFallbackUnlockScreenExist()74     boolean doesFallbackUnlockScreenExist();
75 }
76