public void Dispose() { if (_audioLink != null) { _audioLink.DetachClockListener(this); } _audioLink = null; }
private void HandleUnloaded(object sender, RoutedEventArgs e) { if (this is IClockListener) { _audioLink.DetachClockListener(this as IClockListener); } if (this is IAudioSource) { // May not be attached, but that's ok. _audioLink.DetachSource(this as IAudioSource); } }