[need advice] Trying to continuously check for camera button presses

  • Replies:1
  • OpenNot stickiedAnswered

Jul 10, 2013 7:40:55 AM via Website

(using an HTC Evo 4G LTE as my test device & I am very new to android development)

What I'd like to do is be able to check for every time the camera button on my phone is pressed.

I've tried using broadcast receiver (with a service) but they are only good for one time use, from what I can tell.
There doesn't seem to be any other way from all my searching to detect system events.

(the receiver also won't detect the camera button press, but I'm sure I've got priority and permissions all setup in manifest corectly)

Any ideas?

— modified on Jul 10, 2013 7:47:29 AM

Jul 11, 2013 11:38:58 PM via Website

OK, so I figured it out.

What I had to do was programmatically set up my broadcast receiver, and called a handler at the end of my receiver to re-register it.