public async void CommandBinding_AddVideo(object sender, ExecutedRoutedEventArgs e) { if (!menuAddVideo.IsEnabled) { return; } VideoListItem Result = SearchVideoWindow.Instance(new SearchSettings() { MediaType = MediaType.Video }); if (Result != null) { LayerVideoControl Layer = new LayerVideoControl(); await Layer.OpenMediaAsync(SessionCore.Instance.Business.GetMediaObject(Result.FileName)); SessionCore.Instance.Layers.Add(Layer); } }
public async void CommandBinding_AddVideo(object sender, ExecutedRoutedEventArgs e) { if (!menuAddVideo.IsEnabled) return; VideoListItem Result = SearchVideoWindow.Instance(new SearchSettings() { MediaType = MediaType.Video }); if (Result != null) { LayerVideoControl Layer = new LayerVideoControl(); await Layer.OpenMediaAsync(SessionCore.Instance.Business.GetMediaObject(Result.FileName)); SessionCore.Instance.Layers.Add(Layer); } }