title: Detecting when head phones are plugged in
body: <p>Is there any way to determine, programmatically when headphones are plugged into the computer?</p>
  
  <p>Essentially, I just want to write a simple tool that will mute my sound unless headphones are plugged in. Is this even possible?</p>