How can I disable power menu from long press click on power button in android development?

289 views Asked by At

I've finished trying with KeyEvent.KEYCODE_POWER in onKeyDown override method, execut Root command, dismiss system dialog and abortBroadcast() to prevent power-off or restart from power button's long press click event. But these're not working due to security reasons for android version>9.

Do you think we can use some kind of script to get that on android os?

I hope you're gonna give any idea to try. Thanks..

0

There are 0 answers