Is it possible to prevent the screen turning off when pressing the power button? I run an app on my handset which really needs the screen to remain on for it to function properly. The app already seems to attempt to keep the screen on as the screen timeout seems to be disabled when the app is running, but I can still turn the screen off by tapping the power button.

I do my best not to press the power button, but sometimes I do it by accident.

My question is, is there any way of stopping the power button from turning the screen off? Perhaps there is something the original app developer can do to disable this?

This is on an unrooted device. I'm on Android 4.1.1 , HTC Sense 4+ stock rom
You can prevent lock button from turning off you screen by altering your settings.


Go to your settings
Select Security
Deselect the check box Power button instantly locks