c# - How to detect unplugged headphone jack in WinRT? -


is there way notified whenever headphone jack unplugged in winrt app? want able pause mediaelement playback when happens prevent sound leaking out through loudspeakers.

jack detection notification exposed through immnotificationclient::ondevicestatechanged. tried on win8 desktop, ondevicestatechanged gets called device_state_unplugged , device_state_active when (un)plugging device. sadly part of wasapi documented desktop guess there's no way in winrt.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -