Broadcast receiver that listens to hard button in android
-
19-09-2019 - |
Question
Is there a cross device hard button in android that a background service can listen to and act when it is pressed/released?
Thanks
Solution
No. You can set up a BroadcastReceiver
to watch for the CAMERA or MEDIA buttons, but those are not always available -- some devices do not have the CAMERA button, and the MEDIA button is for use with wired headsets.
Sorry!
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow