Android: Checking if headphones are plugged in

Posted by moppel on Stack Overflow See other posts from Stack Overflow or by moppel
Published on 2010-05-04T11:14:39Z Indexed on 2010/05/04 11:18 UTC
Read the original article Hit count: 157

Filed under:
|

How can I check if headphones are currently plugged in. I don't want a broadcastreceiver which informs me when they have been connected to the device. I need something like:

if(/*headphone is connected*/)
 ...

© Stack Overflow or respective owner

Related posts about android

Related posts about android-sdk