锁屏源码分析

AndroidICS4.0锁屏流程

笑着哭i 提交于 2019-12-04 08:31:03
先来说说LockScreen分类; 一、无锁屏; 二、锁屏: 1、UnLockScreen: 图案锁、 PIN锁, 密码锁; 2、LockScreen: 波纹锁; 接着我们来看看LockScreen的时序图: 综上所述: 1、createUnlockScreenFor()方法创建的是UnLockScreen界面,代码如下: [java] view plain copy print ? View createUnlockScreenFor(UnlockMode unlockMode) { View unlockView = null ; if (DEBUG) Log.d(TAG, "createUnlockScreenFor(" + unlockMode + "): mEnableFallback=" + mEnableFallback); if (unlockMode == UnlockMode.Pattern) { PatternUnlockScreen view = new PatternUnlockScreen( mContext, mConfiguration, mLockPatternUtils, mUpdateMonitor, mKeyguardScreenCallback, mUpdateMonitor.getFailedAttempts()); view