예제 #1
0
        private async void OnGetLyrics()
        {
            var foundLyrics = await _lyricsService.GetLyrics(Track.Artist.Name, Track.Title);

            if (foundLyrics == null)
            {
                _messenger.Send(new ShowDialogMessage(_messenger, MessageType.Info, EditTrackLyricsNotFoundTitle, EditTrackLyricsNotFoundText));
            }
            else
            {
                Track.Lyrics = foundLyrics;
            }
        }
        public Task SetUpUserInterface()
        {
            Console.ForegroundColor = ConsoleColor.Blue;

            Console.Write("Write song title: ");
            var song = _lyricsService.GetLyrics(Console.ReadLine());

            Console.WriteLine("================================================\n" +
                              $"Lyrics for: {song.Author} - {song.Title}\n\n" +
                              $"{song.Lyrics}\n\n" +
                              "================================================");
            if (song.Thumbnail != null)
            {
                Console.WriteLine($"Thumbnail: {song.Thumbnail}");
            }
            if (song.Link != null)
            {
                Console.WriteLine($"Link: {song.Link}");
            }

            return(Task.CompletedTask);
        }
예제 #3
0
 private async Task GetLyrics()
 {
     var _lyrics = await _lyricsService.GetLyrics(_currentSong.SID, _currentSong.SSID);
 }