Example #1
0
        public async void ShowLlink(string Id)
        {
            SearchSongResultById dsr = await BaiduMusicOp.GetMusicUrl(Id);

            this.Dispatcher.Invoke(new Action(() =>
            {
                qs = new QualitySelect(dsr);
                qs.WindowStartupLocation = WindowStartupLocation.CenterScreen;
                qs.ShowDialog();
            }));
        }
Example #2
0
 public QualitySelect(SearchSongResultById dsr)
 {
     InitializeComponent();
     Bitrate = dsr.Bitrate;
     if (Bitrate == null)
     {
         return;
     }
     Bitrate.RemoveAll(b => b.file_bitrate == 0);
     Bitrate.Sort();
     if (Bitrate.Count > 4)
     {
         Bitrate = Bitrate.Take(4).ToList();
     }
     SongInfo             = dsr.songInfo;
     SongInfo.album_title = "专辑:" + SongInfo.album_title;
     this.DataContext     = SongInfo;
 }