public void Dispose() { if (_CallBack != null) { Marshal.ThrowExceptionForHR(_AudioEndPointVolume.UnregisterControlChangeNotify(_CallBack)); _CallBack = null; } }
internal AudioEndpointVolume(IAudioEndpointVolume realEndpointVolume) { _AudioEndPointVolume = realEndpointVolume; _CallBack = new AudioEndpointVolumeCallback(this); Marshal.ThrowExceptionForHR(_AudioEndPointVolume.RegisterControlChangeNotify(_CallBack)); }
internal AudioEndpointVolume(IAudioEndpointVolume realEndpointVolume) { _AudioEndPointVolume = realEndpointVolume; _CallBack = new AudioEndpointVolumeCallback(this); Marshal.ThrowExceptionForHR(_AudioEndPointVolume.RegisterControlChangeNotify( _CallBack)); }