Off screen when the application works

59 views Asked by At

I am making an application that works based on volume button press, when application is on foreground it detects volume up button pressing and do something. it does not requires to keep the screen on while pressing the button. Is there any way to do this ?

1

There are 1 answers

2
therealprashant On

Implement a broadcast reciever which will recive the volume up button action and in its onRecieve() implement your logic.