Dismiss color fade when it is no longer used.
Previously the color fade layers would stay active until the screen was turned back on. After this change, the layers are dismissed as soon as color fade completes. Bug: 24276564 Change-Id: I1f81b397d82d518c2bc921b22f7fe9fd066fc059
This commit is contained in:
@@ -837,6 +837,7 @@ final class DisplayPowerController implements AutomaticBrightnessController.Call
|
||||
if (mPendingScreenOff && target != Display.STATE_OFF) {
|
||||
setScreenState(Display.STATE_OFF);
|
||||
mPendingScreenOff = false;
|
||||
mPowerState.dismissColorFade();
|
||||
}
|
||||
|
||||
if (target == Display.STATE_ON) {
|
||||
@@ -910,6 +911,7 @@ final class DisplayPowerController implements AutomaticBrightnessController.Call
|
||||
// A black surface is already hiding the contents of the screen.
|
||||
setScreenState(Display.STATE_OFF);
|
||||
mPendingScreenOff = false;
|
||||
mPowerState.dismissColorFade();
|
||||
} else if (performScreenOffTransition
|
||||
&& mPowerState.prepareColorFade(mContext,
|
||||
mColorFadeFadesConfig ?
|
||||
|
||||
Reference in New Issue
Block a user