Allow dream to timeout in preview mode
If a dream is started in preview mode, it never times out currently due
to the wakelock which is acquired by the KEEP_SCREEN_ON flag. This
change avoids setting that flag on the dream window when in preview
mode, which allows dream previews to timeout. If dreams are enabled, the
dream will be restarted in non-preview mode after the timeout. Otherwise
the screen will turn off.
Fixes: 271872132
Test: flashed device and verified timeout occurs in preview mode and
dreams remain bright and do not timeout in regular mode.
Flag: NONE
Change-Id: Id47408d714706a426e8eec4ddfeb6d3d7e481335
1 file changed