public void StartCheck() { while (SongQueue.Count > 0) { if (!SongQueue.TryDequeue(out currentSong)) { currentSong = null; continue; } Process(); } }
public void StartDownload() { while (SongQueue.Count > 0) { if (!SongQueue.TryDequeue(out currentSong)) { currentSong = null; continue; } Process(); } //EventBus.Publish(new EventDownloadComplete()); Application.Current.Dispatcher.Invoke(() => EventBus.Publish(new EventDownloadComplete())); }
public void StartMerge() { using (var outputStream = File.Create(Path.Combine(Directory.GetCurrentDirectory(), "final.mp3"))) { while (SongQueue.Count > 0) { if (!SongQueue.TryDequeue(out currentSong)) { currentSong = null; continue; } Process(outputStream); } } }