We've got a tablet application for which we want to screen to timeout after a certain period, but would like the user to re-enable it by touching the screen instead of the 'power'-button on the side of the device.

What's the best approach (battery performance) to this?

Using a Partial Wake Lock (will the screen react?)

Disable the screen in some way, but keep everything (including touch response) working?

3 Answers
3

Since this isn't possible by completely turning the screen off, you may want to just want to use a wake lock and dim the screen to its lowest setting as your 'timeout'. This way you can still accept screen touch events and 'wake' it from this state and bring it back to its previous brightness.

We've got a tablet application for which we want to screen to timeout after a certain period, but would like the user to re-enable it by touching the screen instead of the 'power'-button on the side of the device.

This is impossible except perhaps via custom firmware. If the screen is off, it will not respond to touch events.

Unfortunately I didn't take care of that and don't know the full details. What happened is that we removed the link between 0 brightness and disabling the touch sensors in our Android version / the drivers.
–
GabriëlMay 8 at 6:52