Fix shouldControlUnlockedScreenOff.

This was currently returning true and starting the animation even if
DozeParameters#canControlScreenOff is false. This resulted in
inconsistent state when AOD was disabled, which resulted in blank
screens if the screenoff animation is interrupted.

Fixes: 219043099
Test: atest SystemUITests
Test: atest PlatformScenarioTests:android.platform.test.scenario.sysui.lockscreen
Change-Id: I38a13adeb98cf22594eb55dd169144c546a2ef2a
4 files changed