Пример #1
0
        public async void Play(MediaElement mediaElement)
        {
            try
            {
                Show();
                MinistaPlayer = new MinistaPlayer();
                await MinistaPlayer.Initialize(new Uri(Broadcast.DashPlaybackUrl), mediaElement);

                mediaElement.CurrentStateChanged += MediaElementCurrentStateChanged;
                Hide();
            }
            catch (Exception ex) { ex.PrintException("LiveBroadcastView.Play"); }
        }
Пример #2
0
 public async void Dispose()
 {
     try
     {
         await Dispatcher.RunAsync(Windows.UI.Core.CoreDispatcherPriority.Normal, () =>
         {
             Stop();
             Timer.Stop();
             Timer         = null;
             MinistaPlayer = null;
         });
     }
     catch { }
 }