コード例 #1
0
 /// <summary>
 /// Registers an even client for callbacks
 /// </summary>
 /// <param name="eventClient"></param>
 public void RegisterEventClient(IAudioSessionEventsHandler eventClient)
 {
     // we could have an array or list of listeners if we like
     audioSessionEventCallback = new AudioSessionEventsCallback(eventClient);
     Marshal.ThrowExceptionForHR(audioSessionControlInterface.RegisterAudioSessionNotification(audioSessionEventCallback));
 }
コード例 #2
0
 /// <summary>
 /// Registers an even client for callbacks
 /// </summary>
 /// <param name="eventClient"></param>
 public void RegisterEventClient(IAudioSessionEventsHandler eventClient)
 {
     // we could have an array or list of listeners if we like
     audioSessionEventCallback = new AudioSessionEventsCallback(eventClient);
     Marshal.ThrowExceptionForHR(audioSessionControlInterface.RegisterAudioSessionNotification(audioSessionEventCallback));
 }