I have an app which is used for lets say 4 hours, but only every 5 minutes a user needs to make an input or read the screen. Putting the phone to sleep and locking the screen is a bit annoying. So I have two options:
getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON);
which doesn't lock the screen but the screen is always bright, I would like to dim it while there is no activity. Just because of battery life span, or doesn't that matter that much for these 4 hours?a wake lock
SCREEN_DIM_WAKE_LOCK
which does as well what I want, but I was told rather to use option 1 above.
Can I achieve the wanted somehow without a wake lock?