PowerManager.userActivity() does not turn the display on

1.5k Views Asked by At

I have a count-down timer activity and want to turn the display on when the timer is done. I tried

PowerManager pm = (PowerManager) getSystemService(Context.POWER_SERVICE);
pm.userActivity(SystemClock.uptimeMillis(), false);

but nothing happens, no error reported, display remains off or dimmed. What I'm doing wrong?

0

There are 0 best solutions below