Loading core/res/res/values/config.xml +4 −0 Original line number Diff line number Diff line Loading @@ -1282,6 +1282,10 @@ that can be set by the user. --> <integer name="config_screenBrightnessDoze">1</integer> <!-- Delay that allows some content to arrive at the display before switching from DOZE to ON. --> <integer name="config_wakeUpDelayDoze">0</integer> <!-- Whether or not to skip the initial brightness ramps when the display transitions to STATE_ON. Setting this to true will skip the brightness ramp to the last stored active brightness value and will repeat for the following ramp if autobrightness is enabled. --> Loading core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -3460,4 +3460,5 @@ <java-symbol type="string" name="config_misprovisionedBrandValue" /> <java-symbol type="integer" name="db_wal_truncate_size" /> <java-symbol type="integer" name="config_wakeUpDelayDoze" /> </resources> packages/SystemUI/src/com/android/systemui/statusbar/phone/BiometricUnlockController.java +5 −2 Original line number Diff line number Diff line Loading @@ -108,6 +108,7 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { private StatusBar mStatusBar; private final UnlockMethodCache mUnlockMethodCache; private final Context mContext; private final int mWakeUpDelay; private int mPendingAuthenticatedUserId = -1; private BiometricSourceType mPendingAuthenticatedBioSourceType = null; private boolean mPendingShowBouncer; Loading @@ -131,6 +132,8 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { mScrimController = scrimController; mStatusBar = statusBar; mUnlockMethodCache = unlockMethodCache; mWakeUpDelay = context.getResources().getInteger( com.android.internal.R.integer.config_wakeUpDelayDoze); } public void setStatusBarKeyguardViewManager( Loading Loading @@ -219,7 +222,7 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { // During wake and unlock, we need to draw black before waking up to avoid abrupt // brightness changes due to display state transitions. boolean alwaysOnEnabled = DozeParameters.getInstance(mContext).getAlwaysOn(); boolean delayWakeUp = mode == MODE_WAKE_AND_UNLOCK && alwaysOnEnabled; boolean delayWakeUp = mode == MODE_WAKE_AND_UNLOCK && alwaysOnEnabled && mWakeUpDelay > 0; Runnable wakeUp = ()-> { if (!wasDeviceInteractive) { if (DEBUG_BIO_WAKELOCK) { Loading Loading @@ -271,7 +274,7 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { } mStatusBarWindowController.setStatusBarFocusable(false); if (delayWakeUp) { mHandler.postDelayed(wakeUp, 50); mHandler.postDelayed(wakeUp, mWakeUpDelay); } else { mKeyguardViewMediator.onWakeAndUnlocking(); } Loading Loading
core/res/res/values/config.xml +4 −0 Original line number Diff line number Diff line Loading @@ -1282,6 +1282,10 @@ that can be set by the user. --> <integer name="config_screenBrightnessDoze">1</integer> <!-- Delay that allows some content to arrive at the display before switching from DOZE to ON. --> <integer name="config_wakeUpDelayDoze">0</integer> <!-- Whether or not to skip the initial brightness ramps when the display transitions to STATE_ON. Setting this to true will skip the brightness ramp to the last stored active brightness value and will repeat for the following ramp if autobrightness is enabled. --> Loading
core/res/res/values/symbols.xml +1 −0 Original line number Diff line number Diff line Loading @@ -3460,4 +3460,5 @@ <java-symbol type="string" name="config_misprovisionedBrandValue" /> <java-symbol type="integer" name="db_wal_truncate_size" /> <java-symbol type="integer" name="config_wakeUpDelayDoze" /> </resources>
packages/SystemUI/src/com/android/systemui/statusbar/phone/BiometricUnlockController.java +5 −2 Original line number Diff line number Diff line Loading @@ -108,6 +108,7 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { private StatusBar mStatusBar; private final UnlockMethodCache mUnlockMethodCache; private final Context mContext; private final int mWakeUpDelay; private int mPendingAuthenticatedUserId = -1; private BiometricSourceType mPendingAuthenticatedBioSourceType = null; private boolean mPendingShowBouncer; Loading @@ -131,6 +132,8 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { mScrimController = scrimController; mStatusBar = statusBar; mUnlockMethodCache = unlockMethodCache; mWakeUpDelay = context.getResources().getInteger( com.android.internal.R.integer.config_wakeUpDelayDoze); } public void setStatusBarKeyguardViewManager( Loading Loading @@ -219,7 +222,7 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { // During wake and unlock, we need to draw black before waking up to avoid abrupt // brightness changes due to display state transitions. boolean alwaysOnEnabled = DozeParameters.getInstance(mContext).getAlwaysOn(); boolean delayWakeUp = mode == MODE_WAKE_AND_UNLOCK && alwaysOnEnabled; boolean delayWakeUp = mode == MODE_WAKE_AND_UNLOCK && alwaysOnEnabled && mWakeUpDelay > 0; Runnable wakeUp = ()-> { if (!wasDeviceInteractive) { if (DEBUG_BIO_WAKELOCK) { Loading Loading @@ -271,7 +274,7 @@ public class BiometricUnlockController extends KeyguardUpdateMonitorCallback { } mStatusBarWindowController.setStatusBarFocusable(false); if (delayWakeUp) { mHandler.postDelayed(wakeUp, 50); mHandler.postDelayed(wakeUp, mWakeUpDelay); } else { mKeyguardViewMediator.onWakeAndUnlocking(); } Loading