public void AddLocalMicrophone(LocalMicrophoneModel mic) { if (LocalMicrophones.FirstOrDefault(x => x.Id == mic.Id) == null) { System.Windows.Application.Current.Dispatcher.Invoke(() => { LocalMicrophones.Add(mic); }); Log.Info(string.Format("Added local microphone: name={0} id={1}", mic.DisplayName, mic.Id)); } }
public void RemoveLocalMicrophone(LocalMicrophoneModel mic) { var micToRemove = LocalMicrophones.FirstOrDefault(x => x.Id == mic.Id); if (micToRemove != null) { System.Windows.Application.Current.Dispatcher.Invoke(() => { LocalMicrophones.Remove(micToRemove); }); Log.Info(string.Format("Removed local microphone: name={0} id={1}", micToRemove.DisplayName, micToRemove.Id)); } }
public void SetSelectedAudioContent(LocalMicrophoneModel mic) { var micToSelect = LocalMicrophones.FirstOrDefault(x => x.Id == mic.Id); if (micToSelect != null) { LocalMicrophones.Select(x => { x.IsSharingContent = false; return(x); }) .ToList(); micToSelect.IsSharingContent = true; Log.InfoFormat("Audio content share selected: name={0} id={1}", micToSelect.DisplayName, micToSelect.IsSharingContent); } }
public void SetSelectedLocalMicrophone(LocalMicrophoneModel mic) { var micToSelect = LocalMicrophones.FirstOrDefault(x => x.Id == mic.Id); if (micToSelect != null) { LocalMicrophones.Select(x => { x.IsStreamingAudio = false; return(x); }) .ToList(); micToSelect.IsStreamingAudio = true; Log.Info(string.Format("Local microphone selected: name={0} id={1}", micToSelect.DisplayName, micToSelect.Id)); } }