Beispiel #1
0
 public static void PlayNextSong()
 {
     if (QueueSongNames.Count > 0)
     {
         PlaySongImmediately(QueueSongNames.Dequeue());
     }
 }
Beispiel #2
0
 public static void Update()
 {
     if (MediaPlayer.State == MediaState.Stopped)
     {
         // If we have songs still queued then dequeue the next song name
         if (QueueSongNames.Count > 0)
         {
             CurrentSong = Songs[QueueSongNames.Dequeue()];
             MediaPlayer.Play(CurrentSong);
         }
         // Else just keep playing the song last played
         else if (CurrentSong != null)
         {
             MediaPlayer.Play(CurrentSong);
         }
     }
 }